diff options
author | Lennart Poettering <lennart@poettering.net> | 2015-10-26 17:30:56 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2015-10-27 13:25:55 +0100 |
commit | 5f311f8c0e51e2f13773823feb6a71f7c6f2838c (patch) | |
tree | 6edfc648016e7000715e11c1ede94fde32e88d82 /src/systemctl/systemctl.c | |
parent | e4e73a632524c382139034d4271f53b6089ab4cb (diff) |
util: remove path_get_parent(), in favour of dirname_malloc()
We don't need two functions that do essentialy the same, hence drop
path_get_parent(), and stick to dirname_malloc(), but move it to
path-util.[ch].
Diffstat (limited to 'src/systemctl/systemctl.c')
-rw-r--r-- | src/systemctl/systemctl.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/systemctl/systemctl.c b/src/systemctl/systemctl.c index 49a4b46fd4..054e9eaa13 100644 --- a/src/systemctl/systemctl.c +++ b/src/systemctl/systemctl.c @@ -3479,7 +3479,8 @@ static void print_status_info( dir = mfree(dir); - if (path_get_parent(*dropin, &dir) < 0) { + dir = dirname_malloc(*dropin); + if (!dir) { log_oom(); return; } |