From f8bcbd53be9769f65360c2d7d69a21e3abda4462 Mon Sep 17 00:00:00 2001 From: azv Date: Wed, 17 Jan 2018 14:34:35 +0300 Subject: [PATCH] Issue #2404: Fatal error when create arc in tangent mode Fix crash while preparing presentation of the Tangent constraint --- src/SketcherPrs/SketcherPrs_PositionMgr.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/SketcherPrs/SketcherPrs_PositionMgr.cpp b/src/SketcherPrs/SketcherPrs_PositionMgr.cpp index 85aa05217..3238fb248 100644 --- a/src/SketcherPrs/SketcherPrs_PositionMgr.cpp +++ b/src/SketcherPrs/SketcherPrs_PositionMgr.cpp @@ -332,7 +332,7 @@ std::list getCurves(const GeomPointPtr& thePnt, const SketcherPrs_Sym double aEnd = aCurve->endParam(); GeomCirclePtr aCircle = GeomCirclePtr(new GeomAPI_Circ(aCurve)); GeomPointPtr aProjPnt = aCircle->project(thePnt); - if (thePnt->distance(aProjPnt) <= Precision::Confusion()) + if (aProjPnt && thePnt->distance(aProjPnt) <= Precision::Confusion()) aList.push_back(aResObj); } } -- 2.39.2