diff options
author | Oswald Buddenhagen <[email protected]> | 2020-12-09 12:56:14 +0100 |
---|---|---|
committer | Oswald Buddenhagen <[email protected]> | 2021-02-08 16:23:25 +0000 |
commit | fa6d825c5f241a2da9e417e30debc92068c5e3a5 (patch) | |
tree | 512d2ef65d2e6af07cf1ec1718e259eeabf283b3 /src/plugins/debugger/debuggersourcepathmappingwidget.cpp | |
parent | a673fca1445a0f34b6799d9d60e521c8ae9b68af (diff) |
remove pointless process state checking
this partially reverts ddefe062c7 - contrary to what that commit's
message suggests, the process state doesn't just change out of the blue,
making waitForFinished() return false. that requires the process being
reaped, which may happen only if the event loop runs or one of the
I/O-related waitFor*() functions is called on that process.
note that the first condition in SynchronousProcess::stopProcess() was
actually bogus, as it makes obviously no sense whatsoever to insist that
the process is still running after waitForFinished() returned success.
qtpromaker was also plain broken - it would always terminate prematurely
due to thinking that the sub-process failed.
Change-Id: I44f332a6784ccc7e732ee868e38218f746141129
Reviewed-by: hjk <[email protected]>
Reviewed-by: Orgad Shaneh <[email protected]>
Reviewed-by: Joerg Bornemann <[email protected]>
Diffstat (limited to 'src/plugins/debugger/debuggersourcepathmappingwidget.cpp')
-rw-r--r-- | src/plugins/debugger/debuggersourcepathmappingwidget.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/debugger/debuggersourcepathmappingwidget.cpp b/src/plugins/debugger/debuggersourcepathmappingwidget.cpp index 2f6939c16cf..d73fd47dac4 100644 --- a/src/plugins/debugger/debuggersourcepathmappingwidget.cpp +++ b/src/plugins/debugger/debuggersourcepathmappingwidget.cpp @@ -415,7 +415,7 @@ static QString findQtInstallPath(const FilePath &qmakePath) return QString(); } proc.closeWriteChannel(); - if (!proc.waitForFinished() && proc.state() == QProcess::Running) { + if (!proc.waitForFinished()) { SynchronousProcess::stopProcess(proc); qWarning("%s: Timeout running '%s'.", Q_FUNC_INFO, qPrintable(qmakePath.toString())); return QString(); |