]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
path: log at debug level when we can't query a variable
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Thu, 26 Mar 2020 16:33:43 +0000 (17:33 +0100)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 27 Mar 2020 19:12:45 +0000 (20:12 +0100)
src/path/path.c

index 20892fe1f21882d66883cd2204974caa7cb365b9..5d6afb96f06679ad576c1c75f021dba199809759 100644 (file)
@@ -94,11 +94,11 @@ static int list_homes(void) {
                 int q;
 
                 q = sd_path_lookup(i, arg_suffix, &p);
-                if (q == -ENXIO)
-                        continue;
                 if (q < 0) {
-                        log_error_errno(r, "Failed to query %s: %m", path_table[i]);
-                        r = q;
+                        log_full_errno(q == -ENXIO ? LOG_DEBUG : LOG_ERR,
+                                       q, "Failed to query %s: %m", path_table[i]);
+                        if (q != -ENXIO)
+                                r = q;
                         continue;
                 }