mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-23 18:30:44 +00:00
Don't delete thread in LambdaThread until destructor
* This means a non-self deleting thread can be waited for or queried about still after it's completed.
This commit is contained in:
@@ -338,7 +338,6 @@ public slots:
|
||||
windowsSetName();
|
||||
m_func();
|
||||
m_Thread->quit();
|
||||
m_Thread = NULL;
|
||||
if(m_SelfDelete)
|
||||
deleteLater();
|
||||
completed.acquire();
|
||||
@@ -353,9 +352,9 @@ public:
|
||||
m_func = f;
|
||||
moveToThread(m_Thread);
|
||||
QObject::connect(m_Thread, &QThread::started, this, &LambdaThread::process);
|
||||
QObject::connect(m_Thread, &QThread::finished, m_Thread, &QThread::deleteLater);
|
||||
}
|
||||
|
||||
~LambdaThread() { m_Thread->deleteLater(); }
|
||||
void setName(QString name)
|
||||
{
|
||||
m_Name = name;
|
||||
|
||||
@@ -589,8 +589,8 @@ void CaptureDialog::CheckAndroidSetup(QString &filename)
|
||||
});
|
||||
|
||||
scan->setName(lit("CheckAndroidSetup"));
|
||||
scan->selfDelete(true);
|
||||
scan->start();
|
||||
scan->deleteLater();
|
||||
}
|
||||
|
||||
void CaptureDialog::androidWarn_mouseClick()
|
||||
|
||||
Reference in New Issue
Block a user