From 28028b26b3371756811e95d894f709f4b1207c00 Mon Sep 17 00:00:00 2001 From: Michael Biebl Date: Wed, 18 Dec 2019 18:29:24 +0100 Subject: New upstream version 1.22.0 --- shared/systemd/src/basic/path-util.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'shared/systemd/src/basic/path-util.c') diff --git a/shared/systemd/src/basic/path-util.c b/shared/systemd/src/basic/path-util.c index e39656bc..5bcc35e5 100644 --- a/shared/systemd/src/basic/path-util.c +++ b/shared/systemd/src/basic/path-util.c @@ -6,8 +6,6 @@ #include #include #include -#include -#include #include /* When we include libgen.h because we need dirname() we immediately @@ -22,7 +20,6 @@ #include "glob-util.h" #include "log.h" #include "macro.h" -#include "missing.h" #include "nulstr-util.h" #include "parse-util.h" #include "path-util.h" @@ -276,7 +273,7 @@ char **path_strv_resolve(char **l, const char *root) { } else t = *s; - r = chase_symlinks(t, root, 0, &u); + r = chase_symlinks(t, root, 0, &u, NULL); if (r == -ENOENT) { if (root) { u = TAKE_PTR(orig); @@ -658,7 +655,9 @@ int find_binary(const char *name, char **ret) { return 0; } - last_error = -errno; + /* PATH entries which we don't have access to are ignored, as per tradition. */ + if (errno != EACCES) + last_error = -errno; } return last_error; -- cgit 1.3.0-6-gf8a5