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 <[email protected]>
Cc: Peter Hutterer <[email protected]>
---
 dix/events.c |    6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/dix/events.c b/dix/events.c
index e03e58c..51a04d5 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;
     }
 
-- 
1.7.0

_______________________________________________
[email protected]: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to