changeset 11033:ae74645a557d draft

(svn r15373) -Fix [FS#2606]: Kenobi denied the server's client name to the tab-completed.
author rubidium <rubidium@openttd.org>
date Fri, 06 Feb 2009 15:11:17 +0000
parents 7726de732236
children 6a4aaefa7209
files src/network/network_chat_gui.cpp
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/network/network_chat_gui.cpp
+++ b/src/network/network_chat_gui.cpp
@@ -303,10 +303,10 @@
 
 		/* First, try clients */
 		if (*item < MAX_CLIENT_SLOTS) {
-			if (*item + 1 < GetNetworkClientInfoPoolSize()) {
+			if (*item < GetNetworkClientInfoPoolSize()) {
 				/* Skip inactive clients */
 				NetworkClientInfo *ci;
-				FOR_ALL_CLIENT_INFOS_FROM(ci, *item + 1) break;
+				FOR_ALL_CLIENT_INFOS_FROM(ci, *item) break;
 				if (ci != NULL) {
 					*item = ci->index;
 					return ci->client_name;