[2/3] winex11: Returning more reliable value from X11DRV_MsgWaitForMultipleObjects.

Akihiro Sagawa sagawa.aki at gmail.com
Tue Aug 23 08:13:26 CDT 2016


This patch fixes ole32 test failure with my IME window patch.

After processing several X events, X11DRV_MsgWaitForMultipleObjects always
tells us that a new message is available. This is not true for some cases.

For instance, when we call DestroyWindow, the X queues DestroyEvent. Then,
X11DRV_MsgWaitForMultipleObjects handles the event only; none is posted or
sent as hwnd for destroyed window is unavailable. However, the function
states "new message is available" by returning count - 1 value.

This is an issue for CoWaitForMultipleHandles because it expects a new
message in the queue and consumes the message.

Signed-off-by: Akihiro Sagawa <sagawa.aki at gmail.com>
---
 dlls/winex11.drv/clipboard.c |   6 ++-
 dlls/winex11.drv/event.c     | 115 ++++++++++++++++++++++++-------------------
 dlls/winex11.drv/keyboard.c  |  19 ++++---
 dlls/winex11.drv/mouse.c     |  43 +++++++++-------
 dlls/winex11.drv/window.c    |   5 +-
 dlls/winex11.drv/wintab.c    |  18 ++++---
 dlls/winex11.drv/x11drv.h    |  24 ++++-----
 7 files changed, 130 insertions(+), 100 deletions(-)

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-winex11-Returning-more-reliable-value-from-X11DRV_Ms.patch
Type: text/x-patch
Size: 30363 bytes
Desc: not available
URL: <http://www.winehq.org/pipermail/wine-patches/attachments/20160823/8d0e40a2/attachment-0001.bin>


More information about the wine-patches mailing list