Do not hold the GDI lock while 16-bit ExtDeviceMode is called
Dmitry Timoshkov
dmitry at baikal.ru
Thu Sep 13 03:51:51 CDT 2001
Hello.
Changelog:
Dmitry Timoshkov <dmitry at codeweavers.com>
Do not hold the GDI lock while 16-bit ExtDeviceMode is called.
diff -u cvs/hq/wine/dlls/gdi/driver.c wine/dlls/gdi/driver.c
--- cvs/hq/wine/dlls/gdi/driver.c Wed Aug 22 18:29:53 2001
+++ wine/dlls/gdi/driver.c Thu Sep 13 17:17:41 2001
@@ -378,6 +378,7 @@
HDC hdc;
DC *dc;
INT ret = -1;
+ INT (*pExtDeviceMode)(LPSTR,HWND,LPDEVMODEA,LPSTR,LPSTR,LPDEVMODEA,LPSTR,DWORD);
TRACE("(%04x, %p, %s, %s, %p, %s, %ld)\n",
hwnd, lpdmOutput, lpszDevice, lpszPort, lpdmInput, lpszProfile, fwMode );
@@ -388,10 +389,11 @@
if ((dc = DC_GetDCPtr( hdc )))
{
- if (dc->funcs->pExtDeviceMode)
- ret = dc->funcs->pExtDeviceMode(buf, hwnd, lpdmOutput, lpszDevice, lpszPort,
+ pExtDeviceMode = dc->funcs->pExtDeviceMode;
+ GDI_ReleaseObj( hdc );
+ if (pExtDeviceMode)
+ ret = pExtDeviceMode(buf, hwnd, lpdmOutput, lpszDevice, lpszPort,
lpdmInput, lpszProfile, fwMode);
- GDI_ReleaseObj( hdc );
}
DeleteDC( hdc );
return ret;
More information about the wine-patches
mailing list