Complete.Org: Mailing Lists: Archives: freeciv-dev: October 2004:
[Freeciv-Dev] (PR#10483) Shouldn't be allowed to create players with res
Home

[Freeciv-Dev] (PR#10483) Shouldn't be allowed to create players with res

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: undisclosed-recipients: ;
Subject: [Freeciv-Dev] (PR#10483) Shouldn't be allowed to create players with reserved names
From: "Mike Kaufman" <kaufman@xxxxxxxxxxxxxxxxxxxxxx>
Date: Sat, 9 Oct 2004 14:37:18 -0700
Reply-to: rt@xxxxxxxxxxx

<URL: http://rt.freeciv.org/Ticket/Display.html?id=10483 >

/create observer

is bad. It confuses the server.

Index: server/stdinhand.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/stdinhand.c,v
retrieving revision 1.354.2.2
diff -u -r1.354.2.2 stdinhand.c
--- server/stdinhand.c  7 Oct 2004 03:55:44 -0000       1.354.2.2
+++ server/stdinhand.c  9 Oct 2004 21:35:13 -0000
@@ -133,7 +133,9 @@
       return PNameEmpty;
   } else if (len > MAX_LEN_NAME-1) {
       return PNameTooLong;
-  } else if (strcmp(name, OBSERVER_NAME) == 0 ) {
+  } else if (strcasecmp(name, ANON_PLAYER_NAME) == 0 ) {
+      return PNameIllegal;
+  } else if (strcasecmp(name, OBSERVER_NAME) == 0 ) {
       return PNameIllegal;
   }



[Prev in Thread] Current Thread [Next in Thread]
  • [Freeciv-Dev] (PR#10483) Shouldn't be allowed to create players with reserved names, Mike Kaufman <=