[monitoring-plugins] hopefully fix warning high tide with percentage
RincewindsHat
git at monitoring-plugins.org
Thu Oct 28 16:20:12 CEST 2021
Module: monitoring-plugins
Branch: master
Commit: 1c0882def0d9ce4ed5b2d443884138622e6d839b
Author: RincewindsHat <12514511+RincewindsHat at users.noreply.github.com>
Date: Tue Oct 26 13:05:57 2021 +0200
URL: https://www.monitoring-plugins.org/repositories/monitoring-plugins/commit/?id=1c0882d
hopefully fix warning high tide with percentage
---
plugins/check_disk.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/plugins/check_disk.c b/plugins/check_disk.c
index ecde4e5..1778b61 100644
--- a/plugins/check_disk.c
+++ b/plugins/check_disk.c
@@ -340,7 +340,7 @@ main (int argc, char **argv)
warning_high_tide = path->dtotal_units - path->freespace_units->warning->end;
}
if (path->freespace_percent->warning != NULL) {
- warning_high_tide = llabs( min( (double) warning_high_tide, (1.0 - path->freespace_percent->warning->end / 100 * path->dtotal_units) ));
+ warning_high_tide = llabs( min( (double) warning_high_tide, (double) (1.0 - path->freespace_percent->warning->end/100)* path->dtotal_units ));
}
if (path->freespace_units->critical != NULL) {
critical_high_tide = path->dtotal_units - path->freespace_units->critical->end;
More information about the Commits
mailing list