forked from qt-creator/qt-creator
Utils: Fix possible crash in SynchronousProcess
Disconnect before deleting our data: Otherwise we will get called
via our signals again and then access members that were already
deleted.
Task-number: QTCREATORBUG-4361
Reviewed-by: Friedemann Kleint
(cherry picked from commit 72ae03ba80
)
This commit is contained in:
@@ -251,6 +251,8 @@ SynchronousProcess::SynchronousProcess() :
|
|||||||
|
|
||||||
SynchronousProcess::~SynchronousProcess()
|
SynchronousProcess::~SynchronousProcess()
|
||||||
{
|
{
|
||||||
|
disconnect(&m_d->m_timer, 0, this, 0);
|
||||||
|
disconnect(&m_d->m_process, 0, this, 0);
|
||||||
delete m_d;
|
delete m_d;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user