diff --git a/src/CurveCreator/CurveCreator_Curve.cxx b/src/CurveCreator/CurveCreator_Curve.cxx index 856885bfb..7e37d23ee 100644 --- a/src/CurveCreator/CurveCreator_Curve.cxx +++ b/src/CurveCreator/CurveCreator_Curve.cxx @@ -1093,10 +1093,13 @@ void CurveCreator_Curve::constructAISObject() // myAISShape->SetColor( myCurveColor ); myAISShape->SetWidth( myLineWidth ); Handle(Prs3d_PointAspect) anAspect = myAISShape->Attributes()->PointAspect(); - anAspect->SetScale( 3.0 ); - anAspect->SetTypeOfMarker(Aspect_TOM_O_POINT); - anAspect->SetColor(myPointAspectColor); - myAISShape->Attributes()->SetPointAspect( anAspect ); + if (!anAspect.IsNull()) + { + anAspect->SetScale( 3.0 ); + anAspect->SetTypeOfMarker(Aspect_TOM_O_POINT); + anAspect->SetColor(myPointAspectColor); + myAISShape->Attributes()->SetPointAspect( anAspect ); + } } Handle(AIS_InteractiveObject) CurveCreator_Curve::getAISObject( const bool theNeedToBuild ) const