Salome HOME
0021018: EDF 1592 GEOM: Problems with the radius input field in the Fillet 1D dialog box
[modules/geom.git] / src / GEOMImpl / GEOMImpl_PointDriver.cxx
index 2164fc72c85ff13c10b80dd65a7079f414765111..8af5452e656926f7ee8b4e056f7339b0019e7109 100644 (file)
@@ -1,4 +1,4 @@
-//  Copyright (C) 2007-2008  CEA/DEN, EDF R&D, OPEN CASCADE
+//  Copyright (C) 2007-2010  CEA/DEN, EDF R&D, OPEN CASCADE
 //
 //  Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 //  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
@@ -19,6 +19,7 @@
 //
 //  See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
 //
+
 #include <Standard_Stream.hxx>
 
 #include <GEOMImpl_PointDriver.hxx>
@@ -189,6 +190,10 @@ Standard_Integer GEOMImpl_PointDriver::Execute(TFunction_Logbook& log) const
       Standard_TypeMismatch::Raise
         ("Creation Point On Lines Intersection Aborted : Line shape is not an edge or wire");
     }
+
+    if (aRefShape1.IsSame(aRefShape2))
+      Standard_ConstructionError::Raise("The lines to make intersection must be different");
+
     //Calculate Lines Intersection Point
     BRepExtrema_DistShapeShape dst (aRefShape1, aRefShape2);
     if (dst.IsDone()) {