Module: wine Branch: master Commit: 6a4490d8ab14a26a7647203f83e51b3dda4ff2f1 URL: http://source.winehq.org/git/wine.git/?a=commit;h=6a4490d8ab14a26a7647203f83...
Author: Alexandre Julliard julliard@winehq.org Date: Wed Sep 19 13:12:42 2012 +0200
winex11: Add window data structure locking to the Expose event handler.
---
dlls/winex11.drv/event.c | 7 +++++-- 1 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/dlls/winex11.drv/event.c b/dlls/winex11.drv/event.c index c9ae725..5b50978 100644 --- a/dlls/winex11.drv/event.c +++ b/dlls/winex11.drv/event.c @@ -821,7 +821,7 @@ static void X11DRV_Expose( HWND hwnd, XEvent *xev ) TRACE( "win %p (%lx) %d,%d %dx%d\n", hwnd, event->window, event->x, event->y, event->width, event->height );
- if (!(data = X11DRV_get_win_data( hwnd ))) return; + if (!(data = get_win_data( hwnd ))) return;
rect.left = event->x; rect.top = event->y; @@ -858,7 +858,10 @@ static void X11DRV_Expose( HWND hwnd, XEvent *xev ) } else OffsetRect( &rect, virtual_screen_rect.left, virtual_screen_rect.top );
- if (!data->surface) RedrawWindow( hwnd, &rect, 0, flags ); + if (data->surface) flags = 0; + release_win_data( data ); + + if (flags) RedrawWindow( hwnd, &rect, 0, flags ); }