[Kst] extragear/graphics/kst/src/libkstapp

George Staikos staikos at kde.org
Thu Jun 15 20:24:54 CEST 2006


SVN commit 551843 by staikos:

fix infinitely recursive crashes - coming from kstapp destructor.  the inst
pointer needs to be nulled before deleting the object


 M  +2 -1      kst.cpp  


--- trunk/extragear/graphics/kst/src/libkstapp/kst.cpp #551842:551843
@@ -108,8 +108,9 @@
 const QString& KstApp::defaultTag = KGlobal::staticQString("<Auto Name>");
 
 void KstApp::doubleCheckCleanup() {
-  delete ::inst;
+  KstApp *ptr = ::inst; // guard to prevent double delete on recursion
   ::inst = 0L;
+  delete ptr;
 }
 
 


More information about the Kst mailing list