From 27b1d6ebfb1a6e17b6af887c0474fd8400347ea9 Mon Sep 17 00:00:00 2001 From: Magne Sjaastad Date: Tue, 15 Jun 2021 16:00:47 +0200 Subject: [PATCH] Octave : Always execute command objects in queue before return --- ApplicationLibCode/Application/RiaGuiApplication.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ApplicationLibCode/Application/RiaGuiApplication.cpp b/ApplicationLibCode/Application/RiaGuiApplication.cpp index 74f13726c0..287f19f2a2 100644 --- a/ApplicationLibCode/Application/RiaGuiApplication.cpp +++ b/ApplicationLibCode/Application/RiaGuiApplication.cpp @@ -1582,6 +1582,9 @@ void RiaGuiApplication::slotWorkerProcessFinished( int exitCode, QProcess::ExitS } m_workerProcess = nullptr; + // Always make sure the command objects are executed before any return statement + executeCommandObjects(); + // Either the work process crashed or was aborted by the user if ( exitStatus == QProcess::CrashExit ) { @@ -1590,8 +1593,6 @@ void RiaGuiApplication::slotWorkerProcessFinished( int exitCode, QProcess::ExitS return; } - executeCommandObjects(); - // Exit code != 0 means we have an error if ( exitCode != 0 ) {