summaryrefslogtreecommitdiff
path: root/src/net
diff options
context:
space:
mode:
authorJared Adams <jaxad0127@gmail.com>2010-03-30 13:16:43 -0600
committerJared Adams <jaxad0127@gmail.com>2010-03-30 14:29:28 -0600
commit0c8fd1b9e6a4840bb573c26602f439e7c6ab9d7d (patch)
tree2996cae62236089221bc7c7bad6e834021db6114 /src/net
parent43abf72c78b492fa1cd383dac3990ee331c217ef (diff)
downloadmana-client-0c8fd1b9e6a4840bb573c26602f439e7c6ab9d7d.tar.gz
mana-client-0c8fd1b9e6a4840bb573c26602f439e7c6ab9d7d.tar.bz2
mana-client-0c8fd1b9e6a4840bb573c26602f439e7c6ab9d7d.tar.xz
mana-client-0c8fd1b9e6a4840bb573c26602f439e7c6ab9d7d.zip
Fix some memory issues
Reviewed-by: Thorbjørn Lindeijer
Diffstat (limited to 'src/net')
-rw-r--r--src/net/ea/generalhandler.cpp1
-rw-r--r--src/net/ea/loginhandler.cpp5
-rw-r--r--src/net/ea/loginhandler.h2
3 files changed, 7 insertions, 1 deletions
diff --git a/src/net/ea/generalhandler.cpp b/src/net/ea/generalhandler.cpp
index 021ae08d..749c2409 100644
--- a/src/net/ea/generalhandler.cpp
+++ b/src/net/ea/generalhandler.cpp
@@ -90,7 +90,6 @@ GeneralHandler::GeneralHandler():
mSpecialHandler(new SpecialHandler),
mTradeHandler(new TradeHandler)
{
- //assert(false);
static const Uint16 _messages[] = {
SMSG_CONNECTION_PROBLEM,
0
diff --git a/src/net/ea/loginhandler.cpp b/src/net/ea/loginhandler.cpp
index bec97ed7..730535b8 100644
--- a/src/net/ea/loginhandler.cpp
+++ b/src/net/ea/loginhandler.cpp
@@ -55,6 +55,11 @@ LoginHandler::LoginHandler()
loginHandler = this;
}
+LoginHandler::~LoginHandler()
+{
+ delete_all(mWorlds);
+}
+
void LoginHandler::handleMessage(Net::MessageIn &msg)
{
int code, worldCount;
diff --git a/src/net/ea/loginhandler.h b/src/net/ea/loginhandler.h
index 2fd6c661..4e31e64c 100644
--- a/src/net/ea/loginhandler.h
+++ b/src/net/ea/loginhandler.h
@@ -38,6 +38,8 @@ class LoginHandler : public MessageHandler, public Net::LoginHandler
public:
LoginHandler();
+ ~LoginHandler();
+
void handleMessage(Net::MessageIn &msg);
void connect();