core/service: complain louder if new MAINPID= is refused

This commit is contained in:
Mike Yuan 2024-04-05 18:28:13 +08:00
parent c603f523d0
commit a3980843ef
No known key found for this signature in database
GPG key ID: 417471C0A40F58B3

View file

@ -4381,7 +4381,7 @@ static void service_notify_message(
log_unit_debug(u, "New main PID "PID_FMT" does not belong to service, but we'll accept it as the request to change it came from a privileged process.", new_main_pid.pid);
r = 1;
} else
log_unit_debug(u, "New main PID "PID_FMT" does not belong to service, refusing.", new_main_pid.pid);
log_unit_warning(u, "New main PID "PID_FMT" does not belong to service, refusing.", new_main_pid.pid);
}
if (r > 0) {
(void) service_set_main_pidref(s, TAKE_PIDREF(new_main_pid));