summaryrefslogtreecommitdiffstats
path: root/sockets.c
diff options
context:
space:
mode:
Diffstat (limited to 'sockets.c')
-rw-r--r--sockets.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sockets.c b/sockets.c
index 145236b..da5d99f 100644
--- a/sockets.c
+++ b/sockets.c
@@ -276,14 +276,17 @@ void
rfbCloseClient(cl)
rfbClientPtr cl;
{
+#ifdef HAVE_PTHREADS
pthread_mutex_lock(&cl->updateMutex);
+#endif
FD_CLR(cl->sock,&(cl->screen->allFds));
close(cl->sock);
cl->sock = -1;
+#ifdef HAVE_PTHREADS
pthread_cond_signal(&cl->updateCond);
//pthread_mutex_lock(&cl->updateMutex);
- //rfbClientConnectionGone(cl);
pthread_mutex_unlock(&cl->updateMutex);
+#endif
}