summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/account-server/dalstorage.cpp2
-rw-r--r--src/chat-server/chathandler.cpp6
-rw-r--r--src/chat-server/guild.hpp2
3 files changed, 6 insertions, 4 deletions
diff --git a/src/account-server/dalstorage.cpp b/src/account-server/dalstorage.cpp
index aa29319f..42a35467 100644
--- a/src/account-server/dalstorage.cpp
+++ b/src/account-server/dalstorage.cpp
@@ -1000,10 +1000,10 @@ std::list<Guild*> DALStorage::getGuildList()
guilds.push_back(guild);
}
string_to< unsigned > toUint;
+
/**
* Add the members to the guilds.
*/
-
for (std::list<Guild*>::iterator itr = guilds.begin();
itr != guilds.end();
++itr)
diff --git a/src/chat-server/chathandler.cpp b/src/chat-server/chathandler.cpp
index 43a917ff..d19aa8cf 100644
--- a/src/chat-server/chathandler.cpp
+++ b/src/chat-server/chathandler.cpp
@@ -695,8 +695,10 @@ ChatHandler::handleGuildRetrieveMembers(ChatClient &client, MessageIn &msg)
{
reply.writeByte(ERRMSG_OK);
reply.writeShort(guildId);
- for(std::list<GuildMember*>::const_iterator itr = guild->getMembers().begin();
- itr != guild->getMembers().end(); ++itr)
+ std::list<GuildMember*> memberList = guild->getMembers();
+ std::list<GuildMember*>::const_iterator itr_end = memberList.end();
+ for(std::list<GuildMember*>::iterator itr = memberList.begin();
+ itr != itr_end; ++itr)
{
reply.writeString((*itr)->getName());
reply.writeByte(mPlayerMap.find((*itr)->getName()) != mPlayerMap.end());
diff --git a/src/chat-server/guild.hpp b/src/chat-server/guild.hpp
index ae8120f4..050dc17f 100644
--- a/src/chat-server/guild.hpp
+++ b/src/chat-server/guild.hpp
@@ -124,7 +124,7 @@ class Guild
/**
* Returns the name of the guild.
*/
- const std::string& getName() const
+ std::string getName() const
{ return mName; }
/**