wm: glendy

Download patch

ref: f3bcd178d26e25a52a3dbdd3a054b2ec01eb5b56
parent: aa3452cd2ceba89e653e48704267568ef0808097
author: mkf <mkf@cloud9p.org>
date: Thu Apr 25 02:46:39 EDT 2024

srv: fix build

--- a/srv.c
+++ b/srv.c
@@ -18,6 +18,7 @@
 
 #include "unix.h"
 #include "engine.h"
+// #include "srv.h"
 
 #define playersock sockfd[turn % 2]
 
@@ -26,7 +27,6 @@
 int debug = 1;
 char syncmsg[8];
 
-
 pthread_mutex_t pcount_mutex;
 // pthread_mutex_t print_mutex;
 
@@ -262,7 +262,7 @@
 	{
 		strncpy(syncmsg, s, 7);
 		/* better be safe than sorry */
-		syncmsg[8] = '\0';
+		syncmsg[7] = '\0';
 		dprint("syncmsg = %s\n", syncmsg);
 	}
 }
@@ -303,7 +303,7 @@
 	{
 		strncpy(syncmsg, s, 7);
 		/* better be safe than sorry */
-		syncmsg[8] = '\0';
+		syncmsg[7] = '\0';
 		dprint("syncmsg =  %s\n", syncmsg);
 	}
 }