diff options
Diffstat (limited to 'src/core/unit.c')
-rw-r--r-- | src/core/unit.c | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/src/core/unit.c b/src/core/unit.c index f53bdd5a91..4cffc57793 100644 --- a/src/core/unit.c +++ b/src/core/unit.c @@ -1835,20 +1835,12 @@ int set_unit_path(const char *p) { } char *unit_dbus_path(Unit *u) { - char *p, *e; - assert(u); if (!u->id) return NULL; - if (!(e = bus_path_escape(u->id))) - return NULL; - - p = strappend("/org/freedesktop/systemd1/unit/", e); - free(e); - - return p; + return unit_dbus_path_from_name(u->id); } int unit_add_cgroup(Unit *u, CGroupBonding *b) { |