summaryrefslogtreecommitdiff
path: root/src/animatedsprite.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/animatedsprite.cpp')
-rw-r--r--src/animatedsprite.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/animatedsprite.cpp b/src/animatedsprite.cpp
index 80a2014eb..215fd9ad6 100644
--- a/src/animatedsprite.cpp
+++ b/src/animatedsprite.cpp
@@ -72,7 +72,10 @@ AnimatedSprite *AnimatedSprite::load(const std::string &filename, int variant)
AnimatedSprite::~AnimatedSprite()
{
if (mSprite)
+ {
mSprite->decRef();
+ mSprite = 0;
+ }
}
bool AnimatedSprite::reset()