summaryrefslogtreecommitdiffstats
path: root/cursor.c
diff options
context:
space:
mode:
authordscho <dscho>2001-10-10 15:07:17 +0000
committerdscho <dscho>2001-10-10 15:07:17 +0000
commitfad7881732f39780fecd0a0c678392f002b88e26 (patch)
treee04eb7c43100a2eefd51222fb15550b289c882dd /cursor.c
parent631d3be5408c9b487bb75ecc25177de4901b71d5 (diff)
downloadlibtdevnc-fad7881732f39780fecd0a0c678392f002b88e26.tar.gz
libtdevnc-fad7881732f39780fecd0a0c678392f002b88e26.zip
pthreads corrections
Diffstat (limited to 'cursor.c')
-rw-r--r--cursor.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/cursor.c b/cursor.c
index f04dc84..5663e85 100644
--- a/cursor.c
+++ b/cursor.c
@@ -452,7 +452,11 @@ void rfbPrintXCursor(rfbCursorPtr cursor)
extern void rfbSetCursor(rfbScreenInfoPtr rfbScreen,rfbCursorPtr c,Bool freeOld)
{
LOCK(rfbScreen->cursorMutex);
- rfbUndrawCursor(rfbScreen);
+ while(rfbScreen->cursorIsDrawn) {
+ UNLOCK(rfbScreen->cursorMutex);
+ rfbUndrawCursor(rfbScreen);
+ LOCK(rfbScreen->cursorMutex);
+ }
if(freeOld && rfbScreen->cursor)
rfbFreeCursor(rfbScreen->cursor);