1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2024-12-22 13:33:56 +03:00

pid1: make TimeoutAbortSec settable for transient units

It was documented to be, but implementation was missing.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek 2019-11-27 13:42:57 +01:00
parent a61d68748a
commit e737017b85
2 changed files with 8 additions and 0 deletions

View File

@ -309,6 +309,13 @@ static int bus_service_set_transient_property(
if (streq(name, "TimeoutStopUSec"))
return bus_set_transient_usec(u, name, &s->timeout_stop_usec, message, flags, error);
if (streq(name, "TimeoutAbortUSec")) {
r = bus_set_transient_usec(u, name, &s->timeout_abort_usec, message, flags, error);
if (r >= 0 && !UNIT_WRITE_FLAGS_NOOP(flags))
s->timeout_abort_set = true;
return r;
}
if (streq(name, "RuntimeMaxUSec"))
return bus_set_transient_usec(u, name, &s->runtime_max_usec, message, flags, error);

View File

@ -1485,6 +1485,7 @@ static int bus_append_service_property(sd_bus_message *m, const char *field, con
if (STR_IN_SET(field, "RestartSec",
"TimeoutStartSec",
"TimeoutStopSec",
"TimeoutAbortSec",
"RuntimeMaxSec",
"WatchdogSec"))
return bus_append_parse_sec_rename(m, field, eq);