1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2025-01-07 17:17:44 +03:00

core/service: use log_unit_* where appropriate

(cherry picked from commit 1e8f0beee4272ddc8b25dfa9af8e54bafc4c061a)
(cherry picked from commit b9ff85ece7a6bd9eca158aa0a8af46055ffb6142)
(cherry picked from commit e575661da9)
This commit is contained in:
Mike Yuan 2024-10-26 17:38:06 +02:00 committed by Luca Boccassi
parent e5f6d457d4
commit 12b7b9e50c

View File

@ -4654,7 +4654,7 @@ static int bus_name_pid_lookup_callback(sd_bus_message *reply, void *userdata, s
e = sd_bus_message_get_error(reply);
if (e) {
r = sd_bus_error_get_errno(e);
log_warning_errno(r, "GetConnectionUnixProcessID() failed: %s", bus_error_message(e, r));
log_unit_warning_errno(UNIT(s), r, "GetConnectionUnixProcessID() failed: %s", bus_error_message(e, r));
return 1;
}
@ -4665,7 +4665,7 @@ static int bus_name_pid_lookup_callback(sd_bus_message *reply, void *userdata, s
}
if (!pid_is_valid(pid)) {
log_debug_errno(SYNTHETIC_ERRNO(EINVAL), "GetConnectionUnixProcessID() returned invalid PID");
log_unit_debug_errno(UNIT(s), SYNTHETIC_ERRNO(EINVAL), "GetConnectionUnixProcessID() returned invalid PID");
return 1;
}
@ -4724,7 +4724,7 @@ static void service_bus_name_owner_change(Unit *u, const char *new_owner) {
"s",
s->bus_name);
if (r < 0)
log_debug_errno(r, "Failed to request owner PID of service name, ignoring: %m");
log_unit_debug_errno(u, r, "Failed to request owner PID of service name, ignoring: %m");
}
}