diff options
author | Lennart Poettering <lennart@poettering.net> | 2015-04-07 16:03:45 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2015-04-07 16:03:45 +0200 |
commit | da00518b3f3a8b08d521c4b72068eafa2db566cc (patch) | |
tree | cbfbc00d68a4cc59474a382510e8d5008c2ab594 /src/shared | |
parent | 2c0223282d804ec796c3dc7e0d9087717314ec6a (diff) |
path-util: fix more path_is_mount e792e890f fallout
Diffstat (limited to 'src/shared')
-rw-r--r-- | src/shared/cgroup-util.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/shared/cgroup-util.c b/src/shared/cgroup-util.c index 05c3125aec..b6fa386e90 100644 --- a/src/shared/cgroup-util.c +++ b/src/shared/cgroup-util.c @@ -487,8 +487,10 @@ int cg_get_path(const char *controller, const char *path, const char *suffix, ch int r; r = path_is_mount_point("/sys/fs/cgroup", false); - if (r <= 0) - return r < 0 ? r : -ENOENT; + if (r < 0) + return r; + if (r == 0) + return -ENOENT; /* Cache this to save a few stat()s */ good = true; |