diff options
author | John Crispin <blogic@openwrt.org> | 2013-06-27 19:14:03 +0200 |
---|---|---|
committer | John Crispin <blogic@openwrt.org> | 2013-06-27 20:20:18 +0200 |
commit | 0d44f0de9eacf687182ebebfcb1f9496dbf3bc32 (patch) | |
tree | 7a0aedbf675cda0d5fe4474a0cd653bfcc9d244c | |
parent | 7f31a19db4c88ca17837a2aaa9144622522d0726 (diff) | |
download | unitd-0d44f0de9eacf687182ebebfcb1f9496dbf3bc32.tar unitd-0d44f0de9eacf687182ebebfcb1f9496dbf3bc32.zip |
get rid of sleep() calls
Signed-off-by: John Crispin <blogic@openwrt.org>
-rw-r--r-- | signal.c | 1 | ||||
-rw-r--r-- | state.c | 3 |
2 files changed, 1 insertions, 3 deletions
@@ -26,7 +26,6 @@ static void do_reboot(void) LOG("reboot\n"); fflush(stderr); sync(); - sleep(1); reboot(RB_AUTOBOOT); while (1) ; @@ -63,12 +63,11 @@ static void state_enter(void) case STATE_SHUTDOWN: LOG("- shutdown -\n"); procd_inittab_run("shutdown"); + sync(); break; case STATE_HALT: LOG("- reboot -\n"); - sync(); - sleep(1); reboot(reboot_event); break; |