summaryrefslogtreecommitdiffstats
path: root/main.c
diff options
context:
space:
mode:
authordscho <dscho>2001-10-02 02:44:03 +0000
committerdscho <dscho>2001-10-02 02:44:03 +0000
commit095539cd8c13a18b86f33eec817908cb10c2efbc (patch)
tree98febfaece5012739ec5009ef96d13bd33a8879e /main.c
parentaa8d2ae174f1b00473ec0415e8464599a5eb4564 (diff)
downloadlibtdevnc-095539cd8c13a18b86f33eec817908cb10c2efbc.tar.gz
libtdevnc-095539cd8c13a18b86f33eec817908cb10c2efbc.zip
support for server side colour maps, fix for non-pthread, support for 3bpp
Diffstat (limited to 'main.c')
-rw-r--r--main.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/main.c b/main.c
index d33b7a0..b709bb7 100644
--- a/main.c
+++ b/main.c
@@ -31,7 +31,7 @@
#include <time.h>
#include "rfb.h"
-#include "region.h"
+#include "sraRegion.h"
#ifdef HAVE_PTHREADS
pthread_mutex_t logMutex;
@@ -75,10 +75,14 @@ void rfbMarkRegionAsModified(rfbScreenInfoPtr rfbScreen,sraRegionPtr modRegion)
iterator=rfbGetClientIterator(rfbScreen);
while((cl=rfbClientIteratorNext(iterator))) {
+#ifdef HAVE_PTHREADS
pthread_mutex_lock(&cl->updateMutex);
+#endif
sraRgnOr(cl->modifiedRegion,modRegion);
+#ifdef HAVE_PTHREADS
pthread_cond_signal(&cl->updateCond);
pthread_mutex_unlock(&cl->updateMutex);
+#endif
}
rfbReleaseClientIterator(iterator);
@@ -353,7 +357,9 @@ rfbScreenInfoPtr rfbGetScreen(int argc,char** argv,
format->depth = rfbScreen->depth;
format->bigEndian = rfbEndianTest?FALSE:TRUE;
format->trueColour = TRUE;
- rfbScreen->colourMap = NULL;
+ rfbScreen->colourMap.count = 0;
+ rfbScreen->colourMap.is16 = 0;
+ rfbScreen->colourMap.data.bytes = NULL;
if(bytesPerPixel == 8) {
format->redMax = 7;