(svn r2828) Only command.c needs to know about _docommand_recursive, so make it static. Tell me if there's a problem, because i removed it from network_server.c, but afaict it should be ok
authortron
Sun, 07 Aug 2005 10:03:14 +0000
changeset 2304 f3309898aeb0
parent 2303 458ab5900226
child 2305 f0856e98f7a5
(svn r2828) Only command.c needs to know about _docommand_recursive, so make it static. Tell me if there's a problem, because i removed it from network_server.c, but afaict it should be ok
command.c
network_server.c
variables.h
--- a/command.c	Sat Aug 06 22:40:18 2005 +0000
+++ b/command.c	Sun Aug 07 10:03:14 2005 +0000
@@ -325,6 +325,8 @@
 }
 
 
+static int _docommand_recursive;
+
 int32 DoCommand(int x, int y, uint32 p1, uint32 p2, uint32 flags, uint procc)
 {
 	int32 res;
--- a/network_server.c	Sat Aug 06 22:40:18 2005 +0000
+++ b/network_server.c	Sun Aug 07 10:03:14 2005 +0000
@@ -1353,8 +1353,6 @@
 static void NetworkCheckRestartMap(void)
 {
 	if (_network_restart_game_date != 0 && _cur_year + MAX_YEAR_BEGIN_REAL >= _network_restart_game_date) {
-		_docommand_recursive = 0;
-
 		DEBUG(net, 0)("Auto-restarting map. Year %d reached.", _cur_year + MAX_YEAR_BEGIN_REAL);
 
 		_random_seeds[0][0] = Random();
--- a/variables.h	Sat Aug 06 22:40:18 2005 +0000
+++ b/variables.h	Sun Aug 07 10:03:14 2005 +0000
@@ -271,8 +271,6 @@
 
 VARDEF uint32 _decode_parameters[20];
 
-VARDEF int _docommand_recursive;
-
 VARDEF uint32 _pressed_key; // Low 8 bits = ASCII, High 16 bits = keycode
 VARDEF bool _ctrl_pressed;  // Is Ctrl pressed?
 VARDEF bool _shift_pressed;  // Is Alt pressed?