From de11b9e901d1d1caa0634fad541f08f11c5781af Mon Sep 17 00:00:00 2001 From: megamage Date: Wed, 29 Apr 2009 00:26:07 -0500 Subject: [7730] Some optimizantion and code style. Author: zhenya --HG-- branch : trunk --- src/game/Channel.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/game/Channel.cpp') diff --git a/src/game/Channel.cpp b/src/game/Channel.cpp index 4799539ac62..5524f30b143 100644 --- a/src/game/Channel.cpp +++ b/src/game/Channel.cpp @@ -451,7 +451,7 @@ void Channel::List(Player* player) bool gmInWhoList = sWorld.getConfig(CONFIG_GM_IN_WHO_LIST) || player->GetSession()->GetSecurity() > SEC_PLAYER; uint32 count = 0; - for(PlayerList::iterator i = players.begin(); i != players.end(); ++i) + for(PlayerList::const_iterator i = players.begin(); i != players.end(); ++i) { Player *plr = objmgr.GetPlayer(i->first); @@ -664,7 +664,7 @@ void Channel::SetOwner(uint64 guid, bool exclaim) void Channel::SendToAll(WorldPacket *data, uint64 p) { - for(PlayerList::iterator i = players.begin(); i != players.end(); ++i) + for(PlayerList::const_iterator i = players.begin(); i != players.end(); ++i) { Player *plr = objmgr.GetPlayer(i->first); if(plr) @@ -677,7 +677,7 @@ void Channel::SendToAll(WorldPacket *data, uint64 p) void Channel::SendToAllButOne(WorldPacket *data, uint64 who) { - for(PlayerList::iterator i = players.begin(); i != players.end(); ++i) + for(PlayerList::const_iterator i = players.begin(); i != players.end(); ++i) { if(i->first != who) { -- cgit v1.2.3