diff options
author | Thomas Guyot-Sionnest <dermoth@users.sourceforge.net> | 2007-01-06 06:33:17 +0000 |
---|---|---|
committer | Thomas Guyot-Sionnest <dermoth@users.sourceforge.net> | 2007-01-06 06:33:17 +0000 |
commit | c653cd701020d9a23434cb3b713cabf308666ef8 (patch) | |
tree | a0b3a68a32a4d194c7368f6f5db82dbb6472ba4e /plugins | |
parent | a61a5ead01afeb3eeaf49cfe57978298bd2b9aa6 (diff) | |
download | monitoring-plugins-c653cd701020d9a23434cb3b713cabf308666ef8.tar.gz |
Revert last patch: it works but not really for the reason I though.
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1562 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/check_ping.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/plugins/check_ping.c b/plugins/check_ping.c index a4efc6c1..eb3a6dbf 100644 --- a/plugins/check_ping.c +++ b/plugins/check_ping.c | |||
@@ -399,11 +399,7 @@ validate_arguments () | |||
399 | if (max_packets == -1) | 399 | if (max_packets == -1) |
400 | max_packets = DEFAULT_MAX_PACKETS; | 400 | max_packets = DEFAULT_MAX_PACKETS; |
401 | 401 | ||
402 | max_seconds = crta * max_packets; | 402 | max_seconds = crta / 1000.0 * max_packets + max_packets; |
403 | /* Round up max_seconds because we use only the int part */ | ||
404 | if (max_seconds != (int)max_seconds) | ||
405 | max_seconds = (int)max_seconds + 1; | ||
406 | |||
407 | if (max_seconds > timeout_interval) | 403 | if (max_seconds > timeout_interval) |
408 | timeout_interval = (int)max_seconds; | 404 | timeout_interval = (int)max_seconds; |
409 | 405 | ||