From: Yu Watanabe Date: Mon, 1 Nov 2021 04:48:32 +0000 (+0900) Subject: core: ignore failure on setting smack process label when allowed X-Git-Tag: v250-rc1~377 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=29ff62473b119c0e1d3467148eddcdccc2c9b732;p=thirdparty%2Fsystemd.git core: ignore failure on setting smack process label when allowed --- diff --git a/src/core/execute.c b/src/core/execute.c index 52a4daf0cb6..bf4a66e3bd5 100644 --- a/src/core/execute.c +++ b/src/core/execute.c @@ -4613,7 +4613,7 @@ static int exec_child( * process. This is the latest place before dropping capabilities. Other MAC context are set later. */ if (use_smack) { r = setup_smack(context, executable_fd); - if (r < 0) { + if (r < 0 && !context->smack_process_label_ignore) { *exit_status = EXIT_SMACK_PROCESS_LABEL; return log_unit_error_errno(unit, r, "Failed to set SMACK process label: %m"); }