diff options
author | Jo-Philipp Wich <jow@openwrt.org> | 2009-05-16 17:59:30 +0000 |
---|---|---|
committer | Jo-Philipp Wich <jow@openwrt.org> | 2009-05-16 17:59:30 +0000 |
commit | 6a9d7ac70c824b18aecdbf858e07612e066e094e (patch) | |
tree | 0909b1f3b285ba789d78dbe8b2885c4ef13d010c /contrib/package/freifunk-watchdog/src | |
parent | dc4b478e7b96b2bc0435643e95472a9004274e50 (diff) |
contrib/package/freifunk-watchdog: reset hysteresis counter if test condition is normal
Diffstat (limited to 'contrib/package/freifunk-watchdog/src')
-rw-r--r-- | contrib/package/freifunk-watchdog/src/watchdog.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/contrib/package/freifunk-watchdog/src/watchdog.c b/contrib/package/freifunk-watchdog/src/watchdog.c index b5a573d49e..a0d4e43b1f 100644 --- a/contrib/package/freifunk-watchdog/src/watchdog.c +++ b/contrib/package/freifunk-watchdog/src/watchdog.c @@ -347,10 +347,14 @@ static int do_daemon(void) /* Check crond */ if( find_process("crond") < 0 ) restart_cron++; + else + restart_cron = 0; /* Check SSHd */ if( find_process("dropbear") < 0 ) restart_sshd++; + else + restart_sshd = 0; /* Check wireless interfaces */ ifs = load_wifi_uci(ifs, &modtime); |