From 005747e12db3c40808cd3780b2a9292f3f9b9cfb Mon Sep 17 00:00:00 2001 From: adv Date: Fri, 13 Dec 2013 12:41:30 +0000 Subject: [PATCH] Removing of profiles from stream corrected (Bug #235). --- src/HYDROData/HYDROData_Stream.cxx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/HYDROData/HYDROData_Stream.cxx b/src/HYDROData/HYDROData_Stream.cxx index 22a913c9..b0a2bbdd 100644 --- a/src/HYDROData/HYDROData_Stream.cxx +++ b/src/HYDROData/HYDROData_Stream.cxx @@ -770,6 +770,12 @@ void HYDROData_Stream::removeParameter( const int& theIndex ) if ( !aLabel.FindAttribute( TDataStd_RealArray::GetID(), aParamsArray ) ) return; + if ( aParamsArray->Length() == 1 ) + { + removeParametersArray(); + return; + } + TColStd_Array1OfReal aNewArr( aParamsArray->Lower(), aParamsArray->Upper() - 1 ); for ( int i = aParamsArray->Lower(), j = i, k = 0, n = aParamsArray->Upper(); i <= n; ++i, ++k ) -- 2.39.2