mirror of
https://github.com/troglobit/finit.git
synced 2026-10-17 10:49:34 +00:00
Fix #312: restart services with respawn set, e.g. ttys, immediately
Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
1 parent
bb9bd7e0b0
commit
f6b5b0260b
1 file changed
+8
-3
+8
-3
@@ -2223,10 +2223,15 @@ restart:
|
||||
* which we need to wait for the forked-off child to create its pid
|
||||
* file. In both cases, after that, retry after 2 sec
|
||||
*/
|
||||
if (!svc->respawn)
|
||||
if (!svc->respawn) {
|
||||
dbg("delayed restart of %s", svc_ident(svc, NULL, 0));
|
||||
service_timeout_after(svc, svc->restart_tmo, service_retry);
|
||||
goto done;
|
||||
service_timeout_after(svc, svc->restart_tmo, service_retry);
|
||||
goto done;
|
||||
}
|
||||
|
||||
dbg("respawning %s", svc_ident(svc, NULL, 0));
|
||||
svc_unblock(svc);
|
||||
break;
|
||||
}
|
||||
|
||||
if (svc_is_runtask(svc)) { /* only run/task, not sysv here */
|
||||
|
||||
Reference in new issue
Block a user