diff options
author | Jared Adams <jaxad0127@gmail.com> | 2010-07-28 09:48:16 -0600 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2010-07-28 09:51:49 -0600 |
commit | 07abd88c7e3d606aaa0c8c7387c398d93daae445 (patch) | |
tree | a497b93f613222f9447f820222c775909b760e74 /src/net/tmwa/partyhandler.cpp | |
parent | 04cefb857e2738c103b81f8ac1502f344d84c16f (diff) | |
download | mana-client-07abd88c7e3d606aaa0c8c7387c398d93daae445.tar.gz mana-client-07abd88c7e3d606aaa0c8c7387c398d93daae445.tar.bz2 mana-client-07abd88c7e3d606aaa0c8c7387c398d93daae445.tar.xz mana-client-07abd88c7e3d606aaa0c8c7387c398d93daae445.zip |
Add some null being checks and cleanup some related code
Reviewed-by: Chuck Miller
Diffstat (limited to 'src/net/tmwa/partyhandler.cpp')
-rw-r--r-- | src/net/tmwa/partyhandler.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/net/tmwa/partyhandler.cpp b/src/net/tmwa/partyhandler.cpp index 6983b731..fa3d63f1 100644 --- a/src/net/tmwa/partyhandler.cpp +++ b/src/net/tmwa/partyhandler.cpp @@ -246,8 +246,10 @@ void PartyHandler::handleMessage(Net::MessageIn &msg) partyTab->chatLog(strprintf(_("%s has left your party."), nick.c_str()), BY_SERVER); - Being *b = actorSpriteManager->findBeing(id); - b->setParty(NULL); + if (Being *b = actorSpriteManager->findBeing(id)) + { + b->setParty(NULL); + } taParty->removeMember(id); } |