unit: when JobTimeoutSec= is turned off, implicitly turn off JobRunningTimeoutSec= too
We added JobRunningTimeoutSec= late, and Dracut configured only JobTimeoutSec= to turn of root device timeouts before. With this change we'll propagate a reset of JobTimeoutSec= into JobRunningTimeoutSec=, but only if the latter wasn't set explicitly. This should restore compatibility with older systemd versions. Fixes: #6402
This commit is contained in:
@@ -1082,7 +1082,11 @@ int parse_sec(const char *t, usec_t *usec) {
|
||||
}
|
||||
|
||||
int parse_sec_fix_0(const char *t, usec_t *usec) {
|
||||
assert(t);
|
||||
assert(usec);
|
||||
|
||||
t += strspn(t, WHITESPACE);
|
||||
|
||||
if (streq(t, "0")) {
|
||||
*usec = USEC_INFINITY;
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user