From 1c1811ecafc144151630b3588394e2c345c53aa4 Mon Sep 17 00:00:00 2001 From: Jamey Sharp Date: Tue, 3 Aug 2010 19:49:59 -0700 Subject: CheckDeviceGrabs: Delete redundant pWin->optional test. CheckPassiveGrabsOnWindow returns FALSE if pWin->optional is NULL, because wPassiveGrabs uses wUseDefault, so don't bother checking at the caller. Signed-off-by: Jamey Sharp Reviewed-by: Peter Hutterer Signed-off-by: Peter Hutterer --- dix/events.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/dix/events.c b/dix/events.c index e03e58c02..51a04d526 100644 --- a/dix/events.c +++ b/dix/events.c @@ -3636,8 +3636,7 @@ CheckDeviceGrabs(DeviceIntPtr device, DeviceEvent *event, int checkFirst) for (; i < focus->traceGood; i++) { pWin = focus->trace[i]; - if (pWin->optional && - CheckPassiveGrabsOnWindow(pWin, device, event, sendCore)) + if (CheckPassiveGrabsOnWindow(pWin, device, event, sendCore)) return TRUE; } @@ -3651,8 +3650,7 @@ CheckDeviceGrabs(DeviceIntPtr device, DeviceEvent *event, int checkFirst) for (; i < device->spriteInfo->sprite->spriteTraceGood; i++) { pWin = device->spriteInfo->sprite->spriteTrace[i]; - if (pWin->optional && - CheckPassiveGrabsOnWindow(pWin, device, event, sendCore)) + if (CheckPassiveGrabsOnWindow(pWin, device, event, sendCore)) return TRUE; } -- cgit v1.2.3