RemoteLinux: Don't call mutable expressions inside QTC_ASSERT

In order to conform to the theory: "Removing all
QTC_ASSERTs and QTC_CHECKs should not change anything".

Change-Id: I3f544f8cdcede99d7efa3ba0ef456180203c45be
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
This commit is contained in:
Jarek Kobus
2022-12-14 13:28:56 +01:00
parent a9c675d88d
commit 1dad90ea45

View File

@@ -75,7 +75,7 @@ public:
QProcess::ProcessState state() const;
QString socketFilePath() const
{
QTC_ASSERT(m_masterSocketDir, return QString());
QTC_ASSERT(m_masterSocketDir, return {});
return m_masterSocketDir->path() + "/cs";
}
@@ -1116,8 +1116,8 @@ RunResult LinuxDevicePrivate::runInShell(const CommandLine &cmd, const QByteArra
{
QMutexLocker locker(&m_shellMutex);
DEBUG(cmd.toUserOutput());
QTC_ASSERT(setupShell(), return {});
const bool isSetup = setupShell();
QTC_ASSERT(isSetup, return {});
return m_handler->runInShell(cmd, data);
}