summaryrefslogtreecommitdiffstats
path: root/rfb.h
diff options
context:
space:
mode:
authordscho <dscho>2001-10-04 11:58:57 +0000
committerdscho <dscho>2001-10-04 11:58:57 +0000
commitbd5fdd670ccae30a31d6b007c312b6d2a1a59cc0 (patch)
tree180753d573f8253e7667a763ef63e8c73e8ef57f /rfb.h
parent2a683877ecf21311cd05d4d509e3e2e4e43adae6 (diff)
downloadlibtdevnc-bd5fdd670ccae30a31d6b007c312b6d2a1a59cc0.tar.gz
libtdevnc-bd5fdd670ccae30a31d6b007c312b6d2a1a59cc0.zip
fixed 2 pthreads issues, added noXCursor option.
Diffstat (limited to 'rfb.h')
-rw-r--r--rfb.h27
1 files changed, 13 insertions, 14 deletions
diff --git a/rfb.h b/rfb.h
index e67e683..18bb2fa 100644
--- a/rfb.h
+++ b/rfb.h
@@ -78,20 +78,20 @@ int max(int,int);
#ifdef HAVE_PTHREADS
#include <pthread.h>
#if 0
-#define LOCK(mutex) fprintf(stderr,"%s:%d LOCK(%s)\n",__FILE__,__LINE__,#mutex)
-#define UNLOCK(mutex) fprintf(stderr,"%s:%d UNLOCK(%s)\n",__FILE__,__LINE__,#mutex)
-#define MUTEX(mutex)
-#define INIT_MUTEX(mutex) fprintf(stderr,"%s:%d INIT_MUTEX(%s)\n",__FILE__,__LINE__,#mutex)
+#define LOCK(mutex) fprintf(stderr,"%s:%d LOCK(%s,0x%x)\n",__FILE__,__LINE__,#mutex,&(mutex))
+#define UNLOCK(mutex) fprintf(stderr,"%s:%d UNLOCK(%s,0x%x)\n",__FILE__,__LINE__,#mutex,&(mutex))
+#define MUTEX(mutex) int mutex
+#define INIT_MUTEX(mutex) fprintf(stderr,"%s:%d INIT_MUTEX(%s,0x%x)\n",__FILE__,__LINE__,#mutex,&(mutex))
#define TINI_MUTEX(mutex) fprintf(stderr,"%s:%d TINI_MUTEX(%s)\n",__FILE__,__LINE__,#mutex)
#define SIGNAL(cond) fprintf(stderr,"%s:%d SIGNAL(%s)\n",__FILE__,__LINE__,#cond)
-#define WAIT(cond,mutex) fprintf(stderr,"%s:%d WAIT(%s,%s)\n",__FILE__,__LINE__,#cond,#mutex)
+#define WAIT(cond,mutex) /* fprintf(stderr,"%s:%d WAIT(%s,%s)\n",__FILE__,__LINE__,#cond,#mutex) */
#define COND(cond)
#define INIT_COND(cond) fprintf(stderr,"%s:%d INIT_COND(%s)\n",__FILE__,__LINE__,#cond)
#define TINI_COND(cond) fprintf(stderr,"%s:%d TINI_COND(%s)\n",__FILE__,__LINE__,#cond)
-#define IF_PTHREAD(x)
+#define IF_PTHREADS(x)
#else
-#define LOCK(mutex) pthread_mutex_lock(&(mutex))
-#define UNLOCK(mutex) pthread_mutex_unlock(&(mutex))
+#define LOCK(mutex) pthread_mutex_lock(&(mutex));
+#define UNLOCK(mutex) pthread_mutex_unlock(&(mutex));
#define MUTEX(mutex) pthread_mutex_t (mutex)
#define INIT_MUTEX(mutex) pthread_mutex_init(&(mutex),NULL)
#define TINI_MUTEX(mutex) pthread_mutex_destroy(&(mutex))
@@ -203,10 +203,6 @@ typedef struct
Bool dontSendFramebufferUpdate; /* TRUE while removing or drawing the
cursor */
- /* these variables are needed to save the area under the cursor */
- int cursorX, cursorY,underCursorBufferLen;
- char* underCursorBuffer;
-
/* additions by libvncserver */
rfbPixelFormat rfbServerFormat;
@@ -242,6 +238,11 @@ typedef struct
Bool rfbNeverShared;
Bool rfbDontDisconnect;
struct rfbClientRec* rfbClientHead;
+
+ /* cursor */
+ int cursorX, cursorY,underCursorBufferLen;
+ char* underCursorBuffer;
+ Bool dontConvertRichCursorToXCursor;
struct rfbCursor* cursor;
MUTEX(cursorMutex);
@@ -254,8 +255,6 @@ typedef struct
GetCursorProcPtr getCursorPtr;
SetTranslateFunctionProcPtr setTranslateFunction;
- /* the following members are hooks, i.e. they are called if set,
- but not overriding original functionality */
/* newClientHook is called just after a new client is created */
NewClientHookPtr newClientHook;