From 59228d0dbf91b72be954ac8f93185f32ba4e4f51 Mon Sep 17 00:00:00 2001 From: OMOJOLA JOSHUA <109356020+1awesomeJ@users.noreply.github.com> Date: Wed, 15 Mar 2023 01:12:57 +0100 Subject: src: changed instances of sd_bus_call_method() to bus_call_method() (#26819) * src: changed instances of sd_bus_call_method() to bus_call_method() --- src/fsck/fsck.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'src/fsck') diff --git a/src/fsck/fsck.c b/src/fsck/fsck.c index e25c5d5efa..cfdc6b24bf 100644 --- a/src/fsck/fsck.c +++ b/src/fsck/fsck.c @@ -17,6 +17,7 @@ #include "alloc-util.h" #include "bus-common-errors.h" #include "bus-error.h" +#include "bus-locator.h" #include "bus-util.h" #include "device-util.h" #include "fd-util.h" @@ -53,14 +54,7 @@ static void start_target(const char *target, const char *mode) { log_info("Requesting %s/start/%s", target, mode); /* Start this unit only if we can replace basic.target with it */ - r = sd_bus_call_method(bus, - "org.freedesktop.systemd1", - "/org/freedesktop/systemd1", - "org.freedesktop.systemd1.Manager", - "StartUnitReplace", - &error, - NULL, - "sss", "basic.target", target, mode); + r = bus_call_method(bus, bus_systemd_mgr, "StartUnitReplace", &error, NULL, "sss", "basic.target", target, mode); /* Don't print a warning if we aren't called during startup */ if (r < 0 && !sd_bus_error_has_name(&error, BUS_ERROR_NO_SUCH_JOB)) -- cgit v1.2.1