]> SALOME platform Git repositories - modules/geom.git/commitdiff
Salome HOME
Mantis issue 0022237: Study dump produces a Python code containing syntax errors V6_7_BR V6_7_0 V6_7_0_patch01 V6_7_0rc1
authorjfa <jfa@opencascade.com>
Mon, 1 Jul 2013 06:39:49 +0000 (06:39 +0000)
committerjfa <jfa@opencascade.com>
Mon, 1 Jul 2013 06:39:49 +0000 (06:39 +0000)
src/GEOMImpl/GEOMImpl_IBlocksOperations.cxx

index efb69f42c5f3759a527bf95614a1e9f98dd0f68c..3640533b65ba7bbe4824efa68b22dd5df6c17b59 100644 (file)
@@ -634,13 +634,11 @@ Handle(GEOM_Object) GEOMImpl_IBlocksOperations::GetVertexNearPoint
   anArray->SetValue(1, anIndices.FindIndex(V));
   aResult = GetEngine()->AddSubShape(theShape, anArray);
 
-  // The GetPoint() doesn't change object so no new function is required.
-  Handle(GEOM_Function) aFunction = theShape->GetLastFunction();
+  Handle(GEOM_Function) aFunction = aResult->GetLastFunction();
 
   // Make a Python command
-  GEOM::TPythonDump(aFunction, /*append=*/true)
-    << aResult << " = geompy.GetVertexNearPoint("
-    << theShape << ", " << thePoint << ")";
+  GEOM::TPythonDump(aFunction) << aResult << " = geompy.GetVertexNearPoint("
+                               << theShape << ", " << thePoint << ")";
 
   SetErrorCode(OK);
   return aResult;