forked from qt-creator/qt-creator
QtcProcess: Ensure we set the data just after creating handle
...instead of ensuring in many functions that m_setup isn't null. This amends36c49cd2eaand solves the issue for other functions like processId(), exitCode(), etc... Amends36c49cd2eaChange-Id: I986f7b30e90e5825ae2bb57b4bc2aa14f56e401f Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -337,14 +337,12 @@ int CallerHandle::exitCode() const
|
||||
QString CallerHandle::errorString() const
|
||||
{
|
||||
QTC_ASSERT(isCalledFromCallersThread(), return {});
|
||||
QTC_ASSERT(m_setup.get(), return {});
|
||||
return m_setup->m_errorString;
|
||||
}
|
||||
|
||||
void CallerHandle::setErrorString(const QString &str)
|
||||
{
|
||||
QTC_ASSERT(isCalledFromCallersThread(), return);
|
||||
QTC_ASSERT(m_setup.get(), return);
|
||||
m_setup->m_errorString = str;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user