(svn r3411) - Fix: When changing the server password via the console, actually set the password as well as flag whether it is required.
authorpeter1138
Thu, 19 Jan 2006 21:29:54 +0000
changeset 2863 b30ae0801d49
parent 2862 84cd00442a31
child 2864 0f3ea6f6ff17
(svn r3411) - Fix: When changing the server password via the console, actually set the password as well as flag whether it is required.
console_cmds.c
--- a/console_cmds.c	Thu Jan 19 18:33:20 2006 +0000
+++ b/console_cmds.c	Thu Jan 19 21:29:54 2006 +0000
@@ -1117,8 +1117,10 @@
 	if (strncmp(_network_server_password, "*", NETWORK_PASSWORD_LENGTH) == 0) {
 		_network_server_password[0] = '\0';
 		_network_game_info.use_password = 0;
-	} else
+	} else {
+		ttd_strlcpy(_network_game_info.server_password, _network_server_password, sizeof(_network_server_password));
 		_network_game_info.use_password = 1;
+	}
 
 	return true;
 }