Add validation check for time period for Dpinger (#3190)

This commit is contained in:
Martin Wasley 2019-02-09 19:56:51 +00:00 committed by Ad Schellevis
parent b20f71b19e
commit 7960f2ab77

View File

@ -287,6 +287,8 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
$input_errors[] = gettext("The time period needs to be a numeric value.");
} elseif ($pconfig['time_period'] < 1) {
$input_errors[] = gettext("The time period needs to be positive.");
} elseif ($pconfig['time_period'] < (2.1*$pconfig['interval'])) {
$input_errors[] = gettext("The time period needs at least 2.1 times that of the probe interval.");
}
}