summaryrefslogtreecommitdiff
path: root/src/guildmanager.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2011-08-27 18:41:30 +0300
committerAndrei Karas <akaras@inbox.ru>2011-08-27 18:41:30 +0300
commit26dea46cf8ebcd22c62810bd9c866e7e7e2b6cb2 (patch)
tree5e6ecf428f1716082214db65928848a849f9d109 /src/guildmanager.cpp
parent96ca346fe114804609acea0b13594422f3f09002 (diff)
downloadplus-26dea46cf8ebcd22c62810bd9c866e7e7e2b6cb2.tar.gz
plus-26dea46cf8ebcd22c62810bd9c866e7e7e2b6cb2.tar.bz2
plus-26dea46cf8ebcd22c62810bd9c866e7e7e2b6cb2.tar.xz
plus-26dea46cf8ebcd22c62810bd9c866e7e7e2b6cb2.zip
Fix memory leaks in guildmanager.
Diffstat (limited to 'src/guildmanager.cpp')
-rw-r--r--src/guildmanager.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/guildmanager.cpp b/src/guildmanager.cpp
index bc4158a12..c929e8598 100644
--- a/src/guildmanager.cpp
+++ b/src/guildmanager.cpp
@@ -50,6 +50,7 @@ GuildManager::GuildManager() :
GuildManager::~GuildManager()
{
+ delete mTab;
mTab = 0;
}
@@ -360,3 +361,13 @@ void GuildManager::notice(std::string msg)
else
send("!setmotd " + msg);
}
+
+void GuildManager::clear()
+{
+ if (socialWindow)
+ {
+ Guild *guild = Guild::getGuild(1);
+ if (guild)
+ socialWindow->removeTab(guild);
+ }
+} \ No newline at end of file