Clean up bootstrap-only tasks when leaving bootstrap 'S' runlevel

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
Joachim Nilsson committed 2015-11-26 20:22:24 +01:00
1 parent 8df2b7b6e9
commit b4ccc8b008
4 files changed
+26 -3

No files matched your search

+5 -1
View File
@@ -598,7 +598,8 @@ void service_runlevel(int newlevel)
else
erase("/etc/nologin");
if (0 != prevlevel)
/* No TTYs run at bootstrap, they have a delayed start. */
if (prevlevel > 0)
tty_runlevel(runlevel);
}
@@ -869,6 +870,9 @@ void service_monitor(pid_t lost)
if (lost != svc->pid)
continue;
if (!prevlevel && svc_clean_bootstrap(svc))
continue;
if (SVC_TYPE_SERVICE != svc->type) {
svc->pid = 0;
continue;