changeset 4857:fd1ffc982b64 draft

(svn r6783) -Codechange: Allow ParseConnectionString to allow players with more than one digit
author Darkvater <Darkvater@openttd.org>
date Sun, 15 Oct 2006 23:31:22 +0000
parents 61ac08fe3c29
children 0580b7c31a76
files network.c
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/network.c
+++ b/network.c
@@ -527,8 +527,10 @@
 	char *p;
 	for (p = connection_string; *p != '\0'; p++) {
 		if (*p == '#') {
-			*player = p + 1;
 			*p = '\0';
+			*player = ++p;
+			while (IsValidAsciiChar(*p, CS_NUMERAL)) p++;
+			if (*p == '\0') break;
 		} else if (*p == ':') {
 			*port = p + 1;
 			*p = '\0';