Fix division by zero in Perfdata.php

Fixes #5708

Signed-off-by: Michael Friedrich <Michael.Friedrich@netways.de>
This commit is contained in:
Michael Friedrich 2014-04-06 19:32:10 +02:00
parent ea44ae3693
commit e6bb32be64
1 changed files with 1 additions and 0 deletions

View File

@ -100,6 +100,7 @@ class Perfdata
}
$step = $key;
}
if ($step <= 0) $step = 1;
return $prefix
. number_format($val / $step, 1, ',', '.')
. ' '