DeviceShell: Merge done() and errorOccurred() signals into one

Don't connect to QtcProcess::errorOccurred() signal, as it's going
to be removed soon. Rely on done() signal instead.

Change-Id: I28260f8eb77911a23de80512881cf7220f1bc1fc
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Jarek Kobus
2022-06-17 13:11:08 +02:00
parent 44bb330128
commit 3b0add4b16
3 changed files with 9 additions and 6 deletions

View File

@@ -450,8 +450,11 @@ void DockerDevicePrivate::startContainer()
LOG("Container via process: " << m_container);
m_shell = std::make_unique<ContainerShell>(m_container);
connect(m_shell.get(), &DeviceShell::errorOccurred, this, [this] (QProcess::ProcessError error) {
qCWarning(dockerDeviceLog) << "Container shell encountered error:" << error;
connect(m_shell.get(), &DeviceShell::done, this, [this] (const ProcessResultData &resultData) {
if (resultData.m_error != QProcess::UnknownError)
return;
qCWarning(dockerDeviceLog) << "Container shell encountered error:" << resultData.m_error;
m_shell.reset();
DockerApi::recheckDockerDaemon();