From c261d39c1ae2db872495c2129c05d1154f46b5c3 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Mon, 10 Jun 2013 09:39:42 +0200 Subject: we dont want to continue booting if sysupgrade is in progress Signed-off-by: John Crispin --- preinit.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/preinit.c b/preinit.c index f322be1..c015ebd 100644 --- a/preinit.c +++ b/preinit.c @@ -29,6 +29,11 @@ static void spawn_procd(struct uloop_process *proc, int ret) { char *wdt_fd = watchdog_fd(); char *argv[] = { "/sbin/procd", NULL }; + struct stat s; + + if (!stat("/tmp/sysupgrade", &s)) + while (true) + sleep(1); unsetenv("INITRAMFS"); unsetenv("PREINIT"); -- cgit v1.2.3