From: mpv Date: Mon, 12 May 2014 04:36:18 +0000 (+0400) Subject: Fixed crash on the second item creation X-Git-Tag: V_0.2~77 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=0d71e22684e4cd14613b7c09a90622633ac6a395;p=modules%2Fshaper.git Fixed crash on the second item creation --- diff --git a/src/Model/Model_Document.cpp b/src/Model/Model_Document.cpp index 790bab22f..0255a4f93 100644 --- a/src/Model/Model_Document.cpp +++ b/src/Model/Model_Document.cpp @@ -246,7 +246,7 @@ void Model_Document::addFeature(const boost::shared_ptr theFea } else { // extend array by one more element Handle(TDataStd_HLabelArray1) aNewArray = new TDataStd_HLabelArray1(aRefs->Lower(), aRefs->Upper() + 1); - for(int a = aRefs->Lower(); a < aRefs->Upper(); a++) { + for(int a = aRefs->Lower(); a <= aRefs->Upper(); a++) { aNewArray->SetValue(a, aRefs->Value(a)); } aNewArray->SetValue(aRefs->Upper() + 1, anObjLab);