[PATCH 3/6] user32: Return WAIT_TIMEOUT in nulldrv_MsgWaitForMultipleObjectsEx.

Rémi Bernon rbernon at codeweavers.com
Fri May 14 06:40:06 CDT 2021


When there's nothing to wait for.

Signed-off-by: Rémi Bernon <rbernon at codeweavers.com>
---
 dlls/user32/driver.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/dlls/user32/driver.c b/dlls/user32/driver.c
index 35e206f5e98..cb9dda6a692 100644
--- a/dlls/user32/driver.c
+++ b/dlls/user32/driver.c
@@ -305,6 +305,7 @@ static void CDECL nulldrv_GetDC( HDC hdc, HWND hwnd, HWND top_win, const RECT *w
 static DWORD CDECL nulldrv_MsgWaitForMultipleObjectsEx( DWORD count, const HANDLE *handles, DWORD timeout,
                                                         DWORD mask, DWORD flags )
 {
+    if (!count && !timeout) return WAIT_TIMEOUT;
     return WaitForMultipleObjectsEx( count, handles, flags & MWMO_WAITALL,
                                      timeout, flags & MWMO_ALERTABLE );
 }
-- 
2.31.0




More information about the wine-devel mailing list