(svn r14588) -Fix [FS#2414]: the range for kicking/banning clients is based on the maximum number of clients, not the maximum number of companies.
authorrubidium
Mon, 17 Nov 2008 16:15:55 +0000
changeset 10337 86b3e6838018
parent 10336 9b4b4e1b0668
child 10338 25e120e63390
(svn r14588) -Fix [FS#2414]: the range for kicking/banning clients is based on the maximum number of clients, not the maximum number of companies.
src/network/network_gui.cpp
--- a/src/network/network_gui.cpp	Mon Nov 17 00:41:58 2008 +0000
+++ b/src/network/network_gui.cpp	Mon Nov 17 16:15:55 2008 +0000
@@ -1416,8 +1416,9 @@
 // Here we start to define the options out of the menu
 static void ClientList_Kick(byte client_no)
 {
-	if (client_no < MAX_COMPANIES)
+	if (client_no < MAX_CLIENTS) {
 		SEND_COMMAND(PACKET_SERVER_ERROR)(DEREF_CLIENT(client_no), NETWORK_ERROR_KICKED);
+	}
 }
 
 static void ClientList_Ban(byte client_no)
@@ -1431,7 +1432,7 @@
 		}
 	}
 
-	if (client_no < MAX_COMPANIES) {
+	if (client_no < MAX_CLIENTS) {
 		SEND_COMMAND(PACKET_SERVER_ERROR)(DEREF_CLIENT(client_no), NETWORK_ERROR_KICKED);
 	}
 }