summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSergiy Kibrik <sakib@meta.ua>2015-08-19 18:57:44 +0200
committerJohn Crispin <blogic@openwrt.org>2015-09-15 07:23:32 +0200
commit9cb7be1a3267744ad64b2422e2be4eeb1763d1d2 (patch)
tree055ef839a2f6e9b460b6d67ed84bc5d28e680440
parent03ad6c7fee3d829e1bb541a8d79891d83c00fff1 (diff)
downloadunitd-9cb7be1a3267744ad64b2422e2be4eeb1763d1d2.tar
unitd-9cb7be1a3267744ad64b2422e2be4eeb1763d1d2.zip
inittab: always proceed to next state
If no S or K rc scripts provided we still should be able to go on to next state, or we won't boot properly and would not be able to reboot/shutdown later. Signed-off-by: Sergiy Kibrik <sakib@meta.ua>
-rw-r--r--inittab.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/inittab.c b/inittab.c
index eb402f8..f8f0218 100644
--- a/inittab.c
+++ b/inittab.c
@@ -151,7 +151,10 @@ static void runrc(struct init_action *a)
ERROR("valid format is rcS <S|K> <param>\n");
return;
}
- rcS(a->argv[1], a->argv[2], rcdone);
+
+ /* proceed even if no init or shutdown scripts run */
+ if (rcS(a->argv[1], a->argv[2], rcdone))
+ rcdone(NULL);
}
static void askfirst(struct init_action *a)