summaryrefslogtreecommitdiff
path: root/src/gui/windows/skilldialog.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-08-18 18:51:15 +0300
committerAndrei Karas <akaras@inbox.ru>2016-08-18 18:51:15 +0300
commite469ab2f1940cb04b53bb3b72cc7b5a0cd0669b0 (patch)
treebfeb4a907acd9e0b6838e393eccf3bf6da44ccad /src/gui/windows/skilldialog.cpp
parentc8b1e6e5455dd0c9c51b6b212478ed1e5aa1af4c (diff)
downloadplus-e469ab2f1940cb04b53bb3b72cc7b5a0cd0669b0.tar.gz
plus-e469ab2f1940cb04b53bb3b72cc7b5a0cd0669b0.tar.bz2
plus-e469ab2f1940cb04b53bb3b72cc7b5a0cd0669b0.tar.xz
plus-e469ab2f1940cb04b53bb3b72cc7b5a0cd0669b0.zip
Add some clang fixes.
Diffstat (limited to 'src/gui/windows/skilldialog.cpp')
-rw-r--r--src/gui/windows/skilldialog.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/gui/windows/skilldialog.cpp b/src/gui/windows/skilldialog.cpp
index 69e5f5bf3..b973c09be 100644
--- a/src/gui/windows/skilldialog.cpp
+++ b/src/gui/windows/skilldialog.cpp
@@ -874,8 +874,11 @@ void SkillDialog::useSkillTarget(const SkillInfo *const info,
{
if (!being && autoTarget == AutoTarget_true)
{
- being = localPlayer->setNewTarget(ActorType::Monster,
- AllowSort_true);
+ if (localPlayer)
+ {
+ being = localPlayer->setNewTarget(ActorType::Monster,
+ AllowSort_true);
+ }
}
if (being)
{