Init genericMasks to 0, make sure list is NULL terminated.

This commit is contained in:
Peter Hutterer 2007-06-26 12:58:37 +09:30
parent c4e850a781
commit 8396bf7c8b
2 changed files with 2 additions and 0 deletions

View File

@ -1169,6 +1169,7 @@ CheckDeviceGrabAndHintWindow(WindowPtr pWin, int type,
tempGrab.pointerMode = GrabModeAsync;
tempGrab.confineTo = NullWindow;
tempGrab.cursor = NullCursor;
tempGrab.genericMasks = NULL;
(*dev->deviceGrab.ActivateGrab) (dev, &tempGrab, currentTime, TRUE);
}
}

View File

@ -5912,6 +5912,7 @@ ExtGrabDevice(ClientPtr client,
last->next = xcalloc(1, sizeof(GenericMaskRec));
last = last->next;
*last = *ge_masks;
last->next = NULL;
ge_masks = ge_masks->next;
}
}