wm: glendy

Download patch

ref: 8f274033598243c368c91cbc2ee7d0f0bc041312
parent: 9e0a5d23c342adabef7a82c18c625ba98ade7d9e
author: mkf <mkf@cloud9p.org>
date: Tue May 21 19:26:09 EDT 2024

right...

--- a/srv.c
+++ b/srv.c
@@ -214,8 +214,8 @@
 	char *xpos, *ypos;
 	unsigned int x, y, r;
 
-	xpos = strtok(s, " ");
-	ypos = strtok(nil, " ");
+	ypos = strtok(s, " ");
+	xpos = strtok(nil, " ");
 	
 	if(xpos == nil || ypos == nil)
 	{
--- a/srv4.c
+++ b/srv4.c
@@ -190,8 +190,8 @@
 	char *xpos, *ypos;
 	unsigned int x, y, r;
 
-	xpos = strtok(s, " ");
-	ypos = strtok(nil, " ");
+	ypos = strtok(s, " ");
+	xpos = strtok(nil, " ");
 	
 	if(xpos == nil || ypos == nil)
 	{
@@ -206,9 +206,9 @@
 		"expected string in %s and %s\n", xpos, ypos);
 		return;
 	}
-	
+
+	y = atoi(ypos);	
 	x = atoi(xpos);
-	y = atoi(ypos);
 	
 	dprint("put %d %d\n", x, y);