Code

add deletion of layer_manager to SPDesktop::destroy
authorjohanengelen <johanengelen@users.sourceforge.net>
Thu, 1 Nov 2007 23:19:15 +0000 (23:19 +0000)
committerjohanengelen <johanengelen@users.sourceforge.net>
Thu, 1 Nov 2007 23:19:15 +0000 (23:19 +0000)
src/desktop.cpp

index a97e1f3fc4b731a4b7e5703ca8342a5c4dfdaa68..4fc0e5f60725ca3497cf3ffebd524c815d5647f5 100644 (file)
@@ -336,6 +336,12 @@ void SPDesktop::destroy()
 
     if (_layer_hierarchy) {
         delete _layer_hierarchy;
+//        _layer_hierarchy = NULL; //this should be here, but commented to find other bug somewhere else.
+    }
+
+    if (layer_manager) {
+        delete layer_manager;
+        layer_manager = NULL;
     }
 
     if (_inkscape) {