summaryrefslogtreecommitdiff
path: root/src/animatedsprite.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2011-09-12 02:02:05 +0300
committerAndrei Karas <akaras@inbox.ru>2011-09-12 02:02:05 +0300
commitf457675ecfd704c99e84fe14f0a1dd49a69a9c76 (patch)
tree615a7d18d4302cc82e7d3f711006e445ed237eb7 /src/animatedsprite.cpp
parent8f0a7cbb675ede13658bcc10b045d46fda9c93da (diff)
downloadmanaplus-f457675ecfd704c99e84fe14f0a1dd49a69a9c76.tar.gz
manaplus-f457675ecfd704c99e84fe14f0a1dd49a69a9c76.tar.bz2
manaplus-f457675ecfd704c99e84fe14f0a1dd49a69a9c76.tar.xz
manaplus-f457675ecfd704c99e84fe14f0a1dd49a69a9c76.zip
Add missing checks to some files.
Diffstat (limited to 'src/animatedsprite.cpp')
-rw-r--r--src/animatedsprite.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/animatedsprite.cpp b/src/animatedsprite.cpp
index 27be02e36..fedcd8de2 100644
--- a/src/animatedsprite.cpp
+++ b/src/animatedsprite.cpp
@@ -154,8 +154,8 @@ bool AnimatedSprite::updateCurrentAnimation(unsigned int time)
mFrameIndex = 0;
mFrame = mAnimation->getFrame(mFrameIndex);
-
- if (mFrame->type == Frame::LABEL && !mFrame->nextAction.empty())
+ if (!mFrame || (mFrame->type == Frame::LABEL
+ && !mFrame->nextAction.empty()))
{
fail = true;
}