]> SALOME platform Git repositories - modules/geom.git/commitdiff
Salome HOME
IPAL21676 crash during Node MakeCompound execution
authordmv <dmv@opencascade.com>
Tue, 4 May 2010 12:37:53 +0000 (12:37 +0000)
committerdmv <dmv@opencascade.com>
Tue, 4 May 2010 12:37:53 +0000 (12:37 +0000)
src/GEOM_I_Superv/GEOM_Superv_i.cc

index 95c581f7fafb0303cffc15fb005a0cd5b488c6b0..aa842150ae7fc1c0e492bbc56b31357795c8ebec 100644 (file)
@@ -168,12 +168,13 @@ GEOM::GEOM_List_ptr GEOM_Superv_i::CreateListOfGO()
 //  AddItemToListOfGO:
 //=============================================================================
 void GEOM_Superv_i::AddItemToListOfGO(GEOM::GEOM_List_ptr& theList, 
-                                     GEOM::GEOM_Object_ptr    theObject)
+                                     GEOM::GEOM_Object_ptr theObject)
 {
   MESSAGE("GEOM_Superv_i::AddItemToListOfGO(...)");
+  GEOM::GEOM_Object_var anObj =  GEOM::GEOM_Object::_duplicate(theObject);
   if (GEOM_List_i<GEOM::ListOfGO>* aList = 
       dynamic_cast<GEOM_List_i<GEOM::ListOfGO>*>(GetServant(theList, myPOA).in())) {
-    aList->AddObject(theObject);
+    aList->AddObject(anObj);
     MESSAGE(" NewLength = "<<aList->GetList().length());
   }
 }