summaryrefslogtreecommitdiff
path: root/src/network/network_client.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2008-12-23 08:39:30 +0000
committerrubidium <rubidium@openttd.org>2008-12-23 08:39:30 +0000
commitb4734ee9a4d352785f1332f59c363186abe29695 (patch)
tree195e0e3d8e52be7e4c308d394d03d4468a967c67 /src/network/network_client.cpp
parent94e7f41a9d54a6c1015778f2a84815c28f8b8461 (diff)
downloadopenttd-b4734ee9a4d352785f1332f59c363186abe29695.tar.xz
(svn r14719) -Codechange: replace DEREF_CLIENT with an instance function and replace looping socket structs with info structs when the loop is only interested in the info structs (i.e. not derefing the info from sockets when one can loop info directly and the socket isn't used)
Diffstat (limited to 'src/network/network_client.cpp')
-rw-r--r--src/network/network_client.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/network/network_client.cpp b/src/network/network_client.cpp
index 987614ca7..d6cd1af43 100644
--- a/src/network/network_client.cpp
+++ b/src/network/network_client.cpp
@@ -967,7 +967,7 @@ bool NetworkClientPreferTeamChat(const NetworkClientInfo *cio)
if (!_settings_client.gui.prefer_teamchat || !IsValidCompanyID(cio->client_playas)) return false;
const NetworkClientInfo *ci;
- FOR_ALL_ACTIVE_CLIENT_INFOS(ci) {
+ FOR_ALL_CLIENT_INFOS(ci) {
if (ci->client_playas == cio->client_playas && ci != cio) return true;
}
@@ -979,8 +979,8 @@ bool NetworkClientPreferTeamChat(const NetworkClientInfo *cio)
*/
void NetworkPrintClients()
{
- NetworkClientInfo *ci;
- FOR_ALL_ACTIVE_CLIENT_INFOS(ci) {
+ const NetworkClientInfo *ci;
+ FOR_ALL_CLIENT_INFOS(ci) {
IConsolePrintF(CC_INFO, "Client #%1d name: '%s' company: %1d IP: %s",
ci->client_id,
ci->client_name,