From: eap Date: Tue, 12 Oct 2010 11:39:30 +0000 (+0000) Subject: 0020948: EDF 1468 SMESH: Histogram of the quality controls X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=25b69822a1c1e76c36135b92f627faa31e8812f6;p=modules%2Fsmesh.git 0020948: EDF 1468 SMESH: Histogram of the quality controls fix GetHistogram(), case of 1 value --- diff --git a/src/Controls/SMESH_Controls.cxx b/src/Controls/SMESH_Controls.cxx index 8e943469c..4b370e61b 100644 --- a/src/Controls/SMESH_Controls.cxx +++ b/src/Controls/SMESH_Controls.cxx @@ -314,9 +314,10 @@ void NumericalFunctor::GetHistogram(int nbIntervals, // case of 1 value if (funValues.front() == funValues.back()) { - nbIntervals = 1; - nbEvents.resize( nbIntervals, values.size() ); - funValues.resize( nbIntervals+1); + nbEvents.resize( 1 ); + nbEvents[0] = values.size(); + funValues[1] = funValues.back(); + funValues.resize( 2 ); } // generic case std::multiset< double >::iterator min = values.begin(), max;