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

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/gameengine/SceneGraph/SG_IObject.cpp')
-rw-r--r--source/gameengine/SceneGraph/SG_IObject.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/source/gameengine/SceneGraph/SG_IObject.cpp b/source/gameengine/SceneGraph/SG_IObject.cpp
index 232ceb06958..4787847da0d 100644
--- a/source/gameengine/SceneGraph/SG_IObject.cpp
+++ b/source/gameengine/SceneGraph/SG_IObject.cpp
@@ -128,6 +128,11 @@ ActivateDestructionCallback(
// Call client provided destruction function on this!
m_callbacks.m_destructionfunc(this,m_SGclientObject,m_SGclientInfo);
}
+ else
+ {
+ // no callback but must still destroy the node to avoid memory leak
+ delete this;
+ }
}
void