summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--chart2/source/view/main/VDataSeries.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/chart2/source/view/main/VDataSeries.cxx b/chart2/source/view/main/VDataSeries.cxx
index 6667cbbefca3..8512c19cb4f5 100644
--- a/chart2/source/view/main/VDataSeries.cxx
+++ b/chart2/source/view/main/VDataSeries.cxx
@@ -521,7 +521,7 @@ void VDataSeries::getMinMaxXValue(double& fMin, double& fMax) const
if(aValuesX.getLength() > 0)
{
sal_Int32 i = 0;
- while ( ::rtl::math::isNan( aValuesX[i] ) && i < aValuesX.getLength() )
+ while ( i < aValuesX.getLength() && ::rtl::math::isNan(aValuesX[i]) )
i++;
if ( i < aValuesX.getLength() )
fMax = fMin = aValuesX[i++];