[Kst] extragear/graphics/kst/kst/datasources/planck

George Staikos staikos at kde.org
Wed Sep 21 16:18:39 CEST 2005


SVN commit 462619 by staikos:

memory leak fix from the branch


 M  +8 -6      planckobj.cpp  


--- trunk/extragear/graphics/kst/kst/datasources/planck/planckobj.cpp #462618:462619
@@ -462,16 +462,18 @@
     _PIOFREE(objTypes);
     objTypes = 0L;
 
-    delete[] firstIndex;
-    firstIndex = 0L;
-    delete[] lastIndex;
-    lastIndex = 0L;
-
     objectListSize = 0;
+    _valid = false;
+  }
 
+  delete[] firstIndex;
+  firstIndex = 0L;
+  delete[] lastIndex;
+  lastIndex = 0L;
+
+  if (_group) {
     PIOCloseVoidGrp(&_group);
     _group = 0L;
-    _valid = false;
   }
 }
 


More information about the Kst mailing list