diff options
author | John Crispin <blogic@openwrt.org> | 2013-07-14 11:56:32 +0200 |
---|---|---|
committer | John Crispin <blogic@openwrt.org> | 2013-07-14 11:56:32 +0200 |
commit | 36d79a90c28ac9d655ccd8261b3ac0b497a5aec1 (patch) | |
tree | f0f59d33a833809e3414dbc91f0d6050a593734c /state.c | |
parent | 434865f6f870f89571d7f2f5fa5690d16d6fb1d9 (diff) | |
download | procd-36d79a90c28ac9d655ccd8261b3ac0b497a5aec1.tar.gz |
the cloexec logic of the watchdog was broken
Signed-off-by: John Crispin <blogic@openwrt.org>
Diffstat (limited to 'state.c')
-rw-r--r-- | state.c | 7 |
1 files changed, 3 insertions, 4 deletions
@@ -40,15 +40,14 @@ static void state_enter(void) switch (state) { case STATE_EARLY: LOG("- early -\n"); - watchdog_init(); + watchdog_init(0); hotplug("/etc/hotplug.json"); procd_coldplug(); break; case STATE_INIT: - // check if the wdt appeared during coldplug - if (!watchdog_fd()) - watchdog_init(); + // try to reopen incase the wdt was not available before coldplug + watchdog_init(0); LOG("- init -\n"); log_init(); procd_connect_ubus(); |