aboutsummaryrefslogtreecommitdiff
path: root/src/rc
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2008-10-10 14:53:50 +0000
committerRoy Marples <roy@marples.name>2008-10-10 14:53:50 +0000
commitda94fad3f517c3b95c4eb1f3ee55bfe48b3f4783 (patch)
treef4747aa844e2e52cb0472523d8be5d6c1d3dd4e0 /src/rc
parent10cb4c18df698f0e79688f7d86e388f5d4822d2a (diff)
Re-evaluate sys after running initsh.
Diffstat (limited to 'src/rc')
-rw-r--r--src/rc/rc.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/rc/rc.c b/src/rc/rc.c
index 4b76a6de..d1446cdb 100644
--- a/src/rc/rc.c
+++ b/src/rc/rc.c
@@ -559,6 +559,11 @@ static void do_newlevel(const char *newlevel)
setenv("RC_RUNLEVEL", newlevel, 1);
run_program(INITSH);
+
+ /* init may have mounted /proc so we can now detect or real
+ * sys */
+ if ((sys = rc_sys()))
+ setenv("RC_SYS", sys, 1);
} else if (strcmp(newlevel, RC_LEVEL_SINGLE) == 0) {
#ifndef PREFIX
if (! RUNLEVEL ||