summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2019-03-21 07:46:22 +0300
committerAndrei Karas <akaras@inbox.ru>2019-03-21 07:46:22 +0300
commite2d9aadb03f2e119943aeda0aa63298f1d99d848 (patch)
tree410f9ea8ca1b8d8206ebe20b75381333ceeaf57c
parent6cf5a8dc16c242e7f1fdb1edb8d6fb9ace176076 (diff)
downloadmanaplus-e2d9aadb03f2e119943aeda0aa63298f1d99d848.tar.gz
manaplus-e2d9aadb03f2e119943aeda0aa63298f1d99d848.tar.bz2
manaplus-e2d9aadb03f2e119943aeda0aa63298f1d99d848.tar.xz
manaplus-e2d9aadb03f2e119943aeda0aa63298f1d99d848.zip
Add missing check in ActorManager::addChar
-rw-r--r--src/actormanager.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/actormanager.cpp b/src/actormanager.cpp
index c7926bb8d..732b342b2 100644
--- a/src/actormanager.cpp
+++ b/src/actormanager.cpp
@@ -2286,7 +2286,8 @@ void ActorManager::addChar(const int32_t id,
if (guild != nullptr)
{
GuildMember *const member = guild->getMemberByCharId(id);
- member->setName(name);
+ if (member != nullptr)
+ member->setName(name);
}
}
guiInput->simulateMouseMove();