-
Bug
-
Resolution: Fixed
-
P1: Critical
-
Qt Creator 18.0.0-beta1
-
None
-
67e311249 (18.0)
I current get the following assert relatively often:
QTC_ASSERT(pidEnd != -1 && typeEnd != -1, continue);
in parseShellOutput in deviceshell.cpp.
The contents of "data" is "rm is /usr/bin/rm
1:O:TGludXgK
1:R:MAo=
"
.
When looking at the code I wonder a bit about the combination of the general
connect(m_shellProcess.get(), &Process::readyReadStandardOutput, m_shellProcess.get(), [this] { onReadyRead(); });
after starting the m_shellProcess, and the
m_shellProcess->writeRaw(checkCmd); if (!m_shellProcess->waitForReadyRead()) { ... } QByteArray out = m_shellProcess->readAllRawStandardOutput();
in DeviceShell::checkCommand.
"waitForReadyRead()" doesn't need to mean that all of the output that is lined up for the result of checkCmd is ready to be received. For
checkCommand("mktemp"); checkCommand("rm");
the first readAllRawStandardOutput for "mktemp" could return "mktemp is /us"
and the second readAllRawStandardOutput for "rm" could return "r/bin/mktemp\n"
and leave the "rm is /usr/bin/rm" to be read by the general onReadyRead, leading to this error.
For Gerrit Dashboard: QTCREATORBUG-33495 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
680445,4 | DeviceShell: Fix that responses could only be partially parsed | 18.0 | qt-creator/qt-creator | Status: MERGED | +2 | +1 |