summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordscho <dscho>2001-09-29 15:29:13 +0000
committerdscho <dscho>2001-09-29 15:29:13 +0000
commit641012310eebe3a129c8a1939c3f8c9cd645ef50 (patch)
treeb98ecaf154257ee9c233af64fef3f51ba1eff1f6
parent58031bcb768f927d18ce7f781feff528855eefbd (diff)
downloadlibtdevnc-64101231.tar.gz
libtdevnc-64101231.zip
nother try
-rw-r--r--TODO2
-rw-r--r--cursor.c8
2 files changed, 9 insertions, 1 deletions
diff --git a/TODO b/TODO
index 9ae48c1..2f55df5 100644
--- a/TODO
+++ b/TODO
@@ -4,6 +4,8 @@ immediate:
fix bug in http (java) client with big endian server: byte swapping is broken
cursor "smears" sometimes when not using cursor encoding
really support pthreads.
+ - cursor seems to be undrawn wildly
+ - connection gone and then reconnect is a problem
in the works:
-------------
diff --git a/cursor.c b/cursor.c
index c86e377..19897bb 100644
--- a/cursor.c
+++ b/cursor.c
@@ -224,7 +224,10 @@ rfbCursorPtr rfbMakeXCursor(int width,int height,char* cursorString,char* maskSt
rfbCursorPtr cursor = (rfbCursorPtr)calloc(1,sizeof(rfbCursor));
char* cp;
unsigned char bit;
-
+
+#ifdef HAVE_PTHREADS
+ pthread_mutex_init(&cursor->mutex, NULL);
+#endif
cursor->width=width;
cursor->height=height;
//cursor->backRed=cursor->backGreen=cursor->backBlue=0xffff;
@@ -272,6 +275,9 @@ char* rfbMakeMaskForXCursor(int width,int height,char* source)
void rfbFreeCursor(rfbCursorPtr cursor)
{
if(cursor) {
+#ifdef HAVE_PTHREADS
+ pthread_mutex_destroy(&cursor->mutex);
+#endif
free(cursor->source);
free(cursor->mask);
free(cursor);