Alexandre Julliard : winex11: Don' t try to create the owner window if it belongs to a different thread.

Alexandre Julliard julliard at winehq.org
Tue Mar 2 10:32:32 CST 2010


Module: wine
Branch: master
Commit: 9cd1ce2510536e73cb94dc99ea29a9d189288f64
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=9cd1ce2510536e73cb94dc99ea29a9d189288f64

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Mon Mar  1 17:06:19 2010 +0100

winex11: Don't try to create the owner window if it belongs to a different thread.

---

 dlls/winex11.drv/window.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/dlls/winex11.drv/window.c b/dlls/winex11.drv/window.c
index 1847527..47f7245 100644
--- a/dlls/winex11.drv/window.c
+++ b/dlls/winex11.drv/window.c
@@ -1005,7 +1005,8 @@ static Window get_owner_whole_window( HWND owner )
 
     if (!(data = X11DRV_get_win_data( owner )))
     {
-        if (!(data = X11DRV_create_win_data( owner )))
+        if (GetWindowThreadProcessId( owner, NULL ) != GetCurrentThreadId() ||
+            !(data = X11DRV_create_win_data( owner )))
             return (Window)GetPropA( owner, whole_window_prop );
     }
     else if (!data->managed)  /* make it managed */




More information about the wine-cvs mailing list