Avoid unnecessary window locking in X11DRV_DestroyWindow

Dmitry Timoshkov dmitry at baikal.ru
Mon Mar 7 08:53:17 CST 2005


Hello,

Changelog:
    Dmitry Timoshkov <dmitry at codeweavers.com>
    Avoid unnecessary window locking in X11DRV_DestroyWindow.

--- cvs/hq/wine/dlls/x11drv/window.c	Wed Feb 23 03:06:20 2005
+++ wine/dlls/x11drv/window.c	Mon Mar 07 14:51:20 2005
@@ -836,10 +836,9 @@ BOOL X11DRV_DestroyWindow( HWND hwnd )
 {
     struct x11drv_thread_data *thread_data = x11drv_thread_data();
     Display *display = thread_data->display;
-    WND *wndPtr = WIN_GetPtr( hwnd );
     struct x11drv_win_data *data;
 
-    if (!(data = X11DRV_get_win_data( hwnd ))) goto done;
+    if (!(data = X11DRV_get_win_data( hwnd ))) return TRUE;
 
     destroy_whole_window( display, data );
     destroy_icon_window( display, data );
@@ -852,8 +851,6 @@ BOOL X11DRV_DestroyWindow( HWND hwnd )
     wine_tsx11_unlock();
     HeapFree( GetProcessHeap(), 0, data );
 
- done:
-    WIN_ReleasePtr( wndPtr );
     return TRUE;
 }
 






More information about the wine-patches mailing list