Commit 4f705f6f authored by Alexandros Frantzis's avatar Alexandros Frantzis Committed by Alexandre Julliard

win32u: Avoid iterating over a NULL window list when broadcasting.

parent b159edc6
......@@ -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++)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment