From 07a59bd09cb3ec5c4737164d62f8a51cfcd4ec6e Mon Sep 17 00:00:00 2001 From: Adriaan de Groot Date: Fri, 7 Jun 2019 13:37:46 +0200 Subject: [PATCH] [libcalamares] All commands with workingDirectory failed - This is the same as EFAIL: a block is indented as if it's a multi- line else block. This isn't Python though, and the return always applies. - Add the necessary braces. - Apparently noone uses this code path (until ProcessJob was re- factored to do so). --- src/libcalamares/utils/CalamaresUtilsSystem.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/libcalamares/utils/CalamaresUtilsSystem.cpp b/src/libcalamares/utils/CalamaresUtilsSystem.cpp index c74243ecc..739249cd0 100644 --- a/src/libcalamares/utils/CalamaresUtilsSystem.cpp +++ b/src/libcalamares/utils/CalamaresUtilsSystem.cpp @@ -202,8 +202,10 @@ System::runCommand( if ( QDir( workingPath ).exists() ) process.setWorkingDirectory( QDir( workingPath ).absolutePath() ); else + { cWarning() << "Invalid working directory:" << workingPath; return ProcessResult::Code::NoWorkingDirectory; + } } cDebug() << "Running" << program << RedactedList( arguments );