From: Frantisek Sumsal Date: Mon, 15 May 2023 17:06:14 +0000 (+0200) Subject: nspawn: use the just returned errno in the log message X-Git-Tag: v254-rc1~464^2~7 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e5c275fedc0ab416730fe288a8754a20a014e200;p=thirdparty%2Fsystemd.git nspawn: use the just returned errno in the log message Use the returned errno even though we are going to ignore it, otherwise the log message is just confusing: config.json:119:13: Failed to resolve device node 4:2, ignoring: Success --- diff --git a/src/nspawn/nspawn-oci.c b/src/nspawn/nspawn-oci.c index fc9b763a96b..2b1fae0df4b 100644 --- a/src/nspawn/nspawn-oci.c +++ b/src/nspawn/nspawn-oci.c @@ -874,7 +874,7 @@ static int oci_devices(const char *name, JsonVariant *v, JsonDispatchFlags flags /* Suppress a couple of implicit device nodes */ r = devname_from_devnum(node->mode, makedev(node->major, node->minor), &path); if (r < 0) - json_log(e, flags|JSON_DEBUG, 0, "Failed to resolve device node %u:%u, ignoring: %m", node->major, node->minor); + json_log(e, flags|JSON_DEBUG, r, "Failed to resolve device node %u:%u, ignoring: %m", node->major, node->minor); else { if (PATH_IN_SET(path, "/dev/null",