From 95daa6ccc0e392fa62ecdc92d1b3f4b94d441f03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89milie=20Feral?= Date: Tue, 27 Dec 2016 14:17:23 +0100 Subject: [PATCH] [apps/statistics] Unable the user to set the bar width with a INF/ NAN value Change-Id: I42963c034a269971c332888839b940ea9bdec3c1 --- apps/statistics/histogram_parameter_controller.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/statistics/histogram_parameter_controller.cpp b/apps/statistics/histogram_parameter_controller.cpp index 1a5559cb9..7b0fd34f1 100644 --- a/apps/statistics/histogram_parameter_controller.cpp +++ b/apps/statistics/histogram_parameter_controller.cpp @@ -32,7 +32,7 @@ float HistogramParameterController::parameterAtIndex(int index) { void HistogramParameterController::setParameterAtIndex(int parameterIndex, float f) { assert(parameterIndex >= 0 && parameterIndex < 2); if (parameterIndex == 0) { - if (f <= 0.0f) { + if (f <= 0.0f || isnan(f) || isinf(f)) { app()->displayWarning("Value interdite"); return; }