From 62a80634fa5a3882038cd0b05f4e4d909ce603cf Mon Sep 17 00:00:00 2001 From: Adrian Kummerlaender Date: Fri, 4 Sep 2015 21:43:57 +0200 Subject: [PATCH] Emit `finished` signal even on non-normal exits This is a followup to 7932e3a as it would otherwise be hard to detect processes terminated by internally or externally sent signals. Without this patch the widget continues to operate as if nothing has changed without offering a way to react to the termination from within the application. --- lib/Session.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/Session.cpp b/lib/Session.cpp index 6cf24d0..c295b60 100644 --- a/lib/Session.cpp +++ b/lib/Session.cpp @@ -607,12 +607,12 @@ void Session::done(int exitStatus) } } - if ( !_wantedClose && _shellProcess->exitStatus() != QProcess::NormalExit ) + if ( !_wantedClose && _shellProcess->exitStatus() != QProcess::NormalExit ) { message.sprintf("Session '%s' exited unexpectedly.", _nameTitle.toUtf8().data()); - else - emit finished(); + } + emit finished(); } Emulation * Session::emulation() const