Only reload .conf files when not going to shutdown or reboot

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
Joachim Wiberg
2021-03-11 21:47:22 +01:00
parent 5f026c8149
commit 2c12379a30
+5 -3
View File
@@ -156,9 +156,11 @@ restart:
/* Disable login in single-user mode as well as shutdown/reboot */
nologin();
/* Make sure to (re)load all *.conf in /etc/finit.d/ */
if (conf_any_change())
conf_reload();
if (runlevel != 0 && runlevel != 6) {
/* Make sure to (re)load all *.conf in /etc/finit.d/ */
if (conf_any_change())
conf_reload();
}
/* Reset once flag of runtasks */
service_runtask_clean();