Alexandros Frantzis : win32u: Avoid iterating over a NULL window list when broadcasting.
Alexandre Julliard
julliard at winehq.org
Mon Apr 11 15:55:00 CDT 2022
Module: wine
Branch: master
Commit: 4f705f6f62185de6fa78b88b0aaec554a0fbf0de
URL: https://source.winehq.org/git/wine.git/?a=commit;h=4f705f6f62185de6fa78b88b0aaec554a0fbf0de
Author: Alexandros Frantzis <alexandros.frantzis at collabora.com>
Date: Mon Apr 11 12:53:50 2022 +0300
win32u: Avoid iterating over a NULL window list when broadcasting.
Signed-off-by: Alexandros Frantzis <alexandros.frantzis at collabora.com>
Signed-off-by: Jacek Caban <jacek at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/win32u/message.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/dlls/win32u/message.c b/dlls/win32u/message.c
index 46c42188d70..9479595ae53 100644
--- a/dlls/win32u/message.c
+++ b/dlls/win32u/message.c
@@ -2508,9 +2508,11 @@ static BOOL is_message_broadcastable( UINT msg )
*/
static BOOL broadcast_message( struct send_message_info *info, DWORD_PTR *res_ptr )
{
- if (is_message_broadcastable( info->msg ))
+ HWND *list;
+
+ if (is_message_broadcastable( info->msg ) &&
+ (list = list_window_children( 0, get_desktop_window(), NULL, 0 )))
{
- HWND *list = list_window_children( 0, get_desktop_window(), NULL, 0 );
int i;
for (i = 0; list[i]; i++)
More information about the wine-cvs
mailing list