Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYuri Gorshenin <ygorshenin@chromium.org>2015-03-13 13:47:42 +0300
committerAlex Zolotarev <alex@maps.me>2015-09-23 02:39:06 +0300
commite300e2b4313b9eb2fa9d5ef3cdad1216ffec03fa (patch)
treefe4ba1deabc22930e7e92f05dffb55bf1b04d4e1 /map/anim_phase_chain.cpp
parente8919af8ae240b37a652d93a1b82b969326dd8aa (diff)
[bookmarks] Fixed memory leaks in Bookmarks test.
Diffstat (limited to 'map/anim_phase_chain.cpp')
-rw-r--r--map/anim_phase_chain.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/map/anim_phase_chain.cpp b/map/anim_phase_chain.cpp
index ca7242c66a..8523151bc5 100644
--- a/map/anim_phase_chain.cpp
+++ b/map/anim_phase_chain.cpp
@@ -61,9 +61,8 @@ void InitDefaultPinAnim(AnimPhaseChain * chain)
shared_ptr<anim::Task> CreateDefaultPinAnim(Framework & f, double & scale)
{
- AnimPhaseChain * anim = new AnimPhaseChain(f, scale);
- InitDefaultPinAnim(anim);
-
- return shared_ptr<anim::Task>(anim);
+ shared_ptr<AnimPhaseChain> anim = make_shared<AnimPhaseChain>(f, scale);
+ InitDefaultPinAnim(anim.get());
+ return anim;
}