[Tizen] Fix memory leak issue in dali core 50/132650/1 accepted/tizen/unified/20170608.072246 submit/tizen/20170607.061735
authorminho.sun <minho.sun@samsung.com>
Wed, 7 Jun 2017 05:54:56 +0000 (14:54 +0900)
committerminho.sun <minho.sun@samsung.com>
Wed, 7 Jun 2017 05:54:57 +0000 (14:54 +0900)
This reverts commit 4ad6cb8b91998fd9affe0f185491f76b595c4b74.

Change-Id: I7666fee4e382983e0e83df255ccca796cdaf7f83

dali/internal/event/actors/actor-impl.cpp [changed mode: 0644->0755]
dali/internal/event/actors/actor-impl.h [changed mode: 0644->0755]
dali/internal/update/manager/update-manager.cpp [changed mode: 0644->0755]

old mode 100644 (file)
new mode 100755 (executable)
index 2ab1558..4ad7d29
@@ -2446,6 +2446,7 @@ void Actor::RebuildDepthTree()
 
   SetDepthIndicesMessage( GetEventThreadServices().GetUpdateManager(), sceneGraphNodeDepths );
   DALI_LOG_TIMER_END(depthTimer, gLogFilter, Debug::Concise, "Depth tree create time: ");
+  rootNode->~ActorDepthTreeNode();
 }
 
 /**
old mode 100644 (file)
new mode 100755 (executable)
index b7e177d..e0f200f
@@ -2008,15 +2008,17 @@ public:
   {
     if( mFirstChildNode )
     {
-      delete mFirstChildNode;
+      mFirstChildNode->~ActorDepthTreeNode();
       mFirstChildNode = NULL;
     }
     if( mNextSiblingNode )
     {
-      delete mNextSiblingNode;
+      mNextSiblingNode->~ActorDepthTreeNode();
       mNextSiblingNode = NULL;
     }
     mParentNode = NULL;
+
+    mActors.clear();
   }
 
   uint16_t GetSiblingOrder()
old mode 100644 (file)
new mode 100755 (executable)
index 344891a..c6d67ea
@@ -1053,6 +1053,7 @@ void UpdateManager::SetDepthIndices( NodeDepths* nodeDepths )
     {
       iter->node->SetDepthIndex( iter->sortedDepth );
     }
+    delete nodeDepths;
   }
 }