From 0c35dab0ba366f85b40ef1795125521f1df8c264 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Fri, 28 Mar 2014 00:39:12 +0300 Subject: simplify variables cleanup. --- src/simpleanimation.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/simpleanimation.cpp') diff --git a/src/simpleanimation.cpp b/src/simpleanimation.cpp index 075c98c06..a2c765cb8 100644 --- a/src/simpleanimation.cpp +++ b/src/simpleanimation.cpp @@ -32,6 +32,8 @@ #include "resources/imageset.h" #include "resources/resourcemanager.h" +#include "utils/delete2.h" + #include "debug.h" SimpleAnimation::SimpleAnimation(Animation *const animation) : @@ -62,8 +64,7 @@ SimpleAnimation::SimpleAnimation(const XmlNodePtr animationNode, SimpleAnimation::~SimpleAnimation() { - delete mAnimation; - mAnimation = nullptr; + delete2(mAnimation); if (mImageSet) { mImageSet->decRef(); -- cgit v1.2.3-70-g09d2