From 31938a8560a664c32a9d72f1fc2d4347b232e6e9 Mon Sep 17 00:00:00 2001 From: Michal Schmidt Date: Fri, 28 Nov 2014 13:17:02 +0100 Subject: core: convert log_unit_*() to log_unit_*_errno() Using: find . -name '*.[ch]' | xargs sed -r -i -e \ 's/log_unit_(debug|info|notice|warning|error|emergency)\(([^"]+), "(.*)%s"(.*), strerror\(-([a-zA-Z_]+)\)\);/log_unit_\1_errno(\2, \5, "\3%m"\4);/' --- src/core/execute.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/core/execute.c') diff --git a/src/core/execute.c b/src/core/execute.c index 0f5152fb81..f9011cfef5 100644 --- a/src/core/execute.c +++ b/src/core/execute.c @@ -1550,7 +1550,7 @@ static int exec_child(ExecCommand *command, context->mount_flags); if (err == -EPERM) - log_unit_warning(params->unit_id, "Failed to set up file system namespace due to lack of privileges. Execution sandbox will not be in effect: %s", strerror(-err)); + log_unit_warning_errno(params->unit_id, err, "Failed to set up file system namespace due to lack of privileges. Execution sandbox will not be in effect: %m"); else if (err < 0) { *error = EXIT_NAMESPACE; return err; -- cgit v1.2.3-54-g00ecf