aboutsummaryrefslogtreecommitdiff
path: root/tools/editor
diff options
context:
space:
mode:
authorvolzhs2016-10-31 11:50:34 +0900
committerRémi Verschelde2016-10-31 07:55:23 +0100
commit91af714d39170a502d3691eb6beeeb760e19a0a6 (patch)
tree35078c4e99de2d44813c0261685c48a4321c7927 /tools/editor
parent5033fc92f4464d502d071796a3a1193777509068 (diff)
downloadgodot-91af714d39170a502d3691eb6beeeb760e19a0a6.tar.gz
godot-91af714d39170a502d3691eb6beeeb760e19a0a6.tar.zst
godot-91af714d39170a502d3691eb6beeeb760e19a0a6.zip
Fix memory leak with drag & drop on 2D viewport
(cherry picked from commit a7d492eb53489083181682839c6d7f83a888ad46)
Diffstat (limited to 'tools/editor')
-rw-r--r--tools/editor/plugins/canvas_item_editor_plugin.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/editor/plugins/canvas_item_editor_plugin.cpp b/tools/editor/plugins/canvas_item_editor_plugin.cpp
index 8597a6bf9..87e7696d6 100644
--- a/tools/editor/plugins/canvas_item_editor_plugin.cpp
+++ b/tools/editor/plugins/canvas_item_editor_plugin.cpp
@@ -3746,6 +3746,7 @@ bool CanvasItemEditorViewport::_create_instance(Node* parent, String& path, cons
if (editor->get_edited_scene()->get_filename()!="") { // cyclical instancing
if (_cyclical_dependency_exists(editor->get_edited_scene()->get_filename(), instanced_scene)) {
+ memdelete(instanced_scene);
return false;
}
}