Commit 9d255d6d authored by Tatsuyuki Ishi's avatar Tatsuyuki Ishi Committed by Alexandre Julliard

win32u: Avoid SEGV in QueryDisplayConfig when run as service.

The virtual_monitor used for non-interactive service executions do not have an adapter set. Avoid segfaulting and poisoning the mutex in such cases.
parent 81859c9a
......@@ -2569,6 +2569,9 @@ LONG WINAPI NtUserQueryDisplayConfig( UINT32 flags, UINT32 *paths_count, DISPLAY
if (!(monitor->dev.state_flags & DISPLAY_DEVICE_ACTIVE))
continue;
if (!monitor->adapter)
continue;
adapter_index = monitor->adapter->id;
gpu_luid = &monitor->adapter->gpu_luid;
output_id = monitor->output_id;
......
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