(svn r1102) -Fix: [Console] 'set server_pw' was acting crazy when you typed more
chars then it could take
--- a/console_cmds.c Wed Dec 15 17:31:18 2004 +0000
+++ b/console_cmds.c Wed Dec 15 17:40:12 2004 +0000
@@ -606,7 +606,7 @@
_network_game_info.server_password[0] = '\0';
_network_game_info.use_password = 0;
} else {
- strncpy(_network_game_info.server_password, argv[2], sizeof(_network_game_info.server_password));
+ ttd_strlcpy(_network_game_info.server_password, argv[2], sizeof(_network_game_info.server_password));
_network_game_info.use_password = 1;
}
IConsolePrintF(_iconsole_color_warning, "Game-password changed to '%s'", _network_game_info.server_password);