From: azv Date: Wed, 6 Dec 2017 07:39:31 +0000 (+0300) Subject: Issue #2337: crash when Undo Insert a Folder before X-Git-Tag: V_2.10.0RC~101 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=118887094f1bed1e7c5a5c24395ff26335d83635;p=modules%2Fshaper.git Issue #2337: crash when Undo Insert a Folder before Reinitialize folders iterator each time any folder is removed from the map of labels and corresponding folders. --- diff --git a/src/Model/Model_Objects.cpp b/src/Model/Model_Objects.cpp index 3a933410b..1308ec27f 100644 --- a/src/Model/Model_Objects.cpp +++ b/src/Model/Model_Objects.cpp @@ -898,6 +898,8 @@ void Model_Objects::synchronizeFeatures( // unbind after the "erase" call: on abort sketch // is removes sub-objects that corrupts aFIter myFolders.UnBind(aFldIt.Key()); + // reinitialize iterator because unbind may corrupt the previous order in the map + aFldIt.Initialize(myFolders); } }