https://bugs.winehq.org/show_bug.cgi?id=51614
Bug ID: 51614 Summary: NtGdiSetLayout is missing call to release_dc_ptr(dc) Product: Wine Version: 6.15 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: major Priority: P2 Component: gdi32 Assignee: wine-bugs@winehq.org Reporter: jinoh.kang.kr@gmail.com CC: huw@codeweavers.com, jacek@codeweavers.com, julliard@winehq.org Regression SHA1: 22df510eff3ee66bf02230b46eefef64a5bd8f74 Distribution: ---
Created attachment 70467 --> https://bugs.winehq.org/attachment.cgi?id=70467 Patch to add back release_dc_ptr(dc) to appropriate place
The commit 22df510eff3ee66bf02230b46eefef64a5bd8f74 (gdi32: Use ntgdi interface for SetLayout implementation.) deletes a call to release_dc_ptr(dc) following get_dc_ptr(hdc) in NtGdiSetLayout(HDC,LONG,DWORD).
The thread calling NtGdiSetLayout therefore holds the DC lock indefinitely, preventing other threads from accessing the device context.