Module: wine Branch: master Commit: 860329d61d781b5e7fbfd07b624cc9f4942fbed6 URL: http://source.winehq.org/git/wine.git/?a=commit;h=860329d61d781b5e7fbfd07b62...
Author: Alexandre Julliard julliard@winehq.org Date: Thu Apr 22 16:33:57 2010 +0200
winex11: Add missing X11 locking when setting the cursor.
---
dlls/winex11.drv/mouse.c | 7 +++++-- 1 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/dlls/winex11.drv/mouse.c b/dlls/winex11.drv/mouse.c index b776383..e0e6bb1 100644 --- a/dlls/winex11.drv/mouse.c +++ b/dlls/winex11.drv/mouse.c @@ -301,12 +301,15 @@ static void queue_raw_mouse_message( UINT message, HWND hwnd, DWORD x, DWORD y,
if (hwnd) { + Cursor xcursor; struct x11drv_win_data *data = X11DRV_get_win_data( hwnd ); if (data && cursor != data->cursor) { - Cursor xcursor = get_x11_cursor( cursor ); - if (xcursor) XDefineCursor( gdi_display, data->whole_window, xcursor ); + wine_tsx11_lock(); + if ((xcursor = get_x11_cursor( cursor ))) + XDefineCursor( gdi_display, data->whole_window, xcursor ); data->cursor = cursor; + wine_tsx11_unlock(); } } }