Coverity #209: Fix potential NULL dereference. (Alan Coopersmith)

This commit is contained in:
Daniel Stone 2006-04-09 22:18:20 +03:00
parent 2481b767ae
commit b6771501fe

View file

@ -319,6 +319,8 @@ XkbClientMapPtr map;
tmp= XkbNumRequiredTypes+1;
if (XkbAllocClientMap(xkb,XkbKeyTypesMask,tmp)!=Success)
return NULL;
if (!map)
map = xkb->map;
tmp= 0;
if (map->num_types<=XkbKeypadIndex)
tmp|= XkbKeypadMask;