]> SALOME platform Git repositories - modules/geom.git/commitdiff
Salome HOME
Fix repeated items
authorakl <alexander.kovalev@opencascade.com>
Fri, 20 Jun 2014 08:56:25 +0000 (12:56 +0400)
committerakl <alexander.kovalev@opencascade.com>
Fri, 20 Jun 2014 08:56:25 +0000 (12:56 +0400)
src/GEOM_I/GEOM_Gen_i.cc

index 8f3a876ad03520702917ec57efb237551a8c0044..7fa57d213f46171710e44f9f57230d6f28872d81 100755 (executable)
@@ -3271,8 +3271,12 @@ void GEOM_Gen_i::GetEntriesToCleanStudy(SALOMEDS::Study_ptr theStudy,
         char* aSubEntryStr = new char[aStrLen+1];
         aSubEntry.ToUTF8CString( aSubEntryStr );
         foundIt = aParents.find( aSubEntryStr );
-        if ( foundIt == aParents.end() ) // add to sub-objects if it is not in parents list
+        if ( foundIt == aParents.end() ) // add to sub-objects if it is not in parents list
           aChildren.insert( aSubEntryStr );
+          foundIt = anOthers.find( aSubEntryStr );
+          if ( foundIt != anOthers.end() )
+            anOthers.erase( foundIt );
+        }
       }
     }