summaryrefslogtreecommitdiff
path: root/src/compoundsprite.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/compoundsprite.cpp')
-rw-r--r--src/compoundsprite.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/compoundsprite.cpp b/src/compoundsprite.cpp
index 195a7ce2e..24fc7bbdb 100644
--- a/src/compoundsprite.cpp
+++ b/src/compoundsprite.cpp
@@ -237,8 +237,7 @@ void CompoundSprite::setSprite(const int layer, Sprite *const sprite)
if (mSprites.at(layer) == sprite)
return;
- if (mSprites.at(layer))
- delete mSprites.at(layer);
+ delete mSprites.at(layer);
mSprites[layer] = sprite;
mNeedsRedraw = true;
}