[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
The attached patch fixes a missing XLOCK/XUNLOCK pair in the X11 version
of mouse_driver->select_system_cursor.
--
Elias Pschernig
Index: src/x/xmouse.c
===================================================================
RCS file: /cvsroot/alleg/allegro/src/x/xmouse.c,v
retrieving revision 1.8
diff -u -p -r1.8 xmouse.c
--- src/x/xmouse.c 4 Dec 2004 13:24:17 -0000 1.8
+++ src/x/xmouse.c 14 Mar 2005 13:53:16 -0000
@@ -238,14 +238,18 @@ static int _xwin_select_system_cursor(AL
default:
return 0;
}
-
+
+ XLOCK();
+
if (_xwin.cursor != None) {
XUndefineCursor(_xwin.display, _xwin.window);
XFreeCursor(_xwin.display, _xwin.cursor);
- }
+ }
_xwin.cursor = XCreateFontCursor(_xwin.display, _xwin.cursor_shape);
XDefineCursor(_xwin.display, _xwin.window, _xwin.cursor);
-
+
+ XUNLOCK();
+
return cursor;
}