r22204 by jghali -

scribus-commit scribus-commit at lists.scribus.net
Thu Oct 26 17:21:10 UTC 2017


Author: jghali
Date: Thu Oct 26 17:21:10 2017
New Revision: 22204

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=22204
Log:
#15029: Crash caused by uninitialized variables <u ltd.>

Modified:
    trunk/Scribus/scribus/scribus.cpp

Modified: trunk/Scribus/scribus/scribus.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=22204&path=/trunk/Scribus/scribus/scribus.cpp
==============================================================================
--- trunk/Scribus/scribus/scribus.cpp	(original)
+++ trunk/Scribus/scribus/scribus.cpp	Thu Oct 26 17:21:10 2017
@@ -310,6 +310,8 @@
 	//ScQApp->setAttribute(Qt::AA_DontShowIconsInMenus);
 	//noIcon = IconManager::instance()->loadPixmap("noicon.png");
 #endif
+	m_doc = 0;
+	m_tocGenerator = 0;
 }
 
 /*
@@ -465,8 +467,10 @@
 		delete actionManager;
 	if (appModeHelper)
 		delete appModeHelper;
-	delete m_doc;
-	delete m_tocGenerator;
+	if (m_doc)
+		delete m_doc;
+	if (m_tocGenerator)
+		delete m_tocGenerator;
 }
 
 void ScribusMainWindow::addScToolBar(ScToolBar *tb, QString name)




More information about the scribus-commit mailing list