[Kdenlive-devel] [PATCH 30/37] slotDvdWizard: Use QPointer
Mikko Rapeli
mikko.rapeli at iki.fi
Thu Jun 28 13:53:08 UTC 2012
Fixes crashes if parent is destroyed. Found by krazy. Details at:
http://blogs.kde.org/node/3919
---
src/mainwindow.cpp | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index 3cef476..aba469b 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -3847,9 +3847,10 @@ void MainWindow::slotDvdWizard(const QString &url, const QString &profile)
// We must stop the monitors since we create a new on in the dvd wizard
m_clipMonitor->stop();
m_projectMonitor->stop();
- DvdWizard w(url, profile, this);
- w.exec();
+ QPointer<DvdWizard> w = new DvdWizard(url, profile, this);
+ w->exec();
m_projectMonitor->start();
+ delete w;
}
void MainWindow::slotShowTimeline(bool show)
--
1.7.10.4
More information about the Kdenlive
mailing list