summaryrefslogtreecommitdiff
path: root/src/utils/chatutils.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-07-21 00:47:44 +0300
committerAndrei Karas <akaras@inbox.ru>2015-07-21 00:47:44 +0300
commitfffbd86a1014ad169ed2d68ea58cdddf346faa14 (patch)
tree713c96fcf7421ca87f638d312e752179281cb8fe /src/utils/chatutils.cpp
parent1941b81a5a278f26a5d7e1f91903ab04c92e2cd1 (diff)
downloadmanaverse-fffbd86a1014ad169ed2d68ea58cdddf346faa14.tar.gz
manaverse-fffbd86a1014ad169ed2d68ea58cdddf346faa14.tar.bz2
manaverse-fffbd86a1014ad169ed2d68ea58cdddf346faa14.tar.xz
manaverse-fffbd86a1014ad169ed2d68ea58cdddf346faa14.zip
Add missing checks and non null attributes.
Diffstat (limited to 'src/utils/chatutils.cpp')
-rw-r--r--src/utils/chatutils.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/utils/chatutils.cpp b/src/utils/chatutils.cpp
index c5b7e25ad..17ee9e11a 100644
--- a/src/utils/chatutils.cpp
+++ b/src/utils/chatutils.cpp
@@ -158,7 +158,9 @@ void replaceVars(std::string &str)
StringVect names;
std::string newStr;
const Party *party = nullptr;
- if (localPlayer->isInParty() && (party = localPlayer->getParty()))
+ if (localPlayer->isInParty() &&
+ (party = localPlayer->getParty()) &&
+ party)
{
party->getNames(names);
FOR_EACH (StringVectCIter, it, names)