Revert "dix: deduplicate callers of DeliverDeviceEvents in DeliverGrabbedEvents"
This call was supposed to have no functional changes but in some cases
DeliverDeviceEvents() was called with a uninitialised win variable.
Revert, safer than trying to sort this out otherwise.
This reverts commit 6eff14a789
.
Reported-by: Mathieu Taillefumier <mathieu.taillefumier@free.fr>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
This commit is contained in:
parent
85cecd9811
commit
f92ba92adf
18
dix/events.c
18
dix/events.c
|
@ -4266,7 +4266,6 @@ DeliverGrabbedEvent(InternalEvent *event, DeviceIntPtr thisDev,
|
||||||
if (grab->ownerEvents)
|
if (grab->ownerEvents)
|
||||||
{
|
{
|
||||||
WindowPtr focus;
|
WindowPtr focus;
|
||||||
WindowPtr win;
|
|
||||||
|
|
||||||
/* Hack: Some pointer device have a focus class. So we need to check
|
/* Hack: Some pointer device have a focus class. So we need to check
|
||||||
* for the type of event, to see if we really want to deliver it to
|
* for the type of event, to see if we really want to deliver it to
|
||||||
|
@ -4283,16 +4282,15 @@ DeliverGrabbedEvent(InternalEvent *event, DeviceIntPtr thisDev,
|
||||||
else
|
else
|
||||||
focus = PointerRootWin;
|
focus = PointerRootWin;
|
||||||
if (focus == PointerRootWin)
|
if (focus == PointerRootWin)
|
||||||
{
|
deliveries = DeliverDeviceEvents(pSprite->win, event, grab,
|
||||||
win = pSprite->win;
|
NullWindow, thisDev);
|
||||||
focus = NullWindow;
|
else if (focus && (focus == pSprite->win ||
|
||||||
} else if (focus && (focus == pSprite->win ||
|
IsParent(focus, pSprite->win)))
|
||||||
IsParent(focus, pSprite->win)))
|
deliveries = DeliverDeviceEvents(pSprite->win, event, grab, focus,
|
||||||
win = pSprite->win;
|
thisDev);
|
||||||
else if (focus)
|
else if (focus)
|
||||||
win = focus;
|
deliveries = DeliverDeviceEvents(focus, event, grab, focus,
|
||||||
|
thisDev);
|
||||||
deliveries = DeliverDeviceEvents(win, event, grab, focus, thisDev);
|
|
||||||
}
|
}
|
||||||
if (!deliveries)
|
if (!deliveries)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue