aboutsummaryrefslogtreecommitdiff
path: root/src/rc/rc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/rc/rc.c')
-rw-r--r--src/rc/rc.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/rc/rc.c b/src/rc/rc.c
index ec11a472..7af7103a 100644
--- a/src/rc/rc.c
+++ b/src/rc/rc.c
@@ -856,11 +856,14 @@ main(int argc, char **argv)
signal_setup(SIGUSR1, handle_signal);
signal_setup(SIGWINCH, handle_signal);
- rc_plugin_load();
-
/* Run any special sysinit foo */
- if (newlevel && strcmp(newlevel, RC_LEVEL_SYSINIT) == 0)
+ if (newlevel && strcmp(newlevel, RC_LEVEL_SYSINIT) == 0) {
do_sysinit();
+ free(runlevel);
+ runlevel = rc_runlevel_get();
+ }
+
+ rc_plugin_load();
/* Now we start handling our children */
signal_setup(SIGCHLD, handle_signal);