Utils: Weaken QTC_CHECK in QtcProcess::stdErr()

The previous tighter check is actually good theoretically, but currently
ShellCommand::runFullySynchronous triggers it and disentangling there
is not trivial. So weaken it a bit for now to not annoy users.

Change-Id: Ifc6b5713b398db0af0f604834c37ff361c2a1ed3
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
hjk
2021-08-11 16:41:49 +02:00
parent e88b4ebce8
commit 4000819262

View File

@@ -876,7 +876,11 @@ QString QtcProcess::stdOut() const
QString QtcProcess::stdErr() const
{
QTC_CHECK(d->m_stdErr.keepRawData);
// FIXME: The tighter check below is actually good theoretically, but currently
// ShellCommand::runFullySynchronous triggers it and disentangling there
// is not trivial. So weaken it a bit for now.
//QTC_CHECK(d->m_stdErr.keepRawData);
QTC_CHECK(d->m_stdErr.keepRawData || d->m_stdErr.rawData.isEmpty());
return normalizeNewlines(d->m_codec->toUnicode(d->m_stdErr.rawData));
}