0001013: 0.13 program crash

This commit is contained in:
wmayer 2013-02-17 08:43:21 +01:00
parent 374370d3f4
commit 3b80f64e6c

View File

@ -197,6 +197,8 @@ const TopoDS_Face SketchBased::getSupportFace() const {
Part::Feature* SketchBased::getSupport() const {
// get the support of the Sketch if any
if (!Sketch.getValue())
return 0;
App::DocumentObject* SupportLink = static_cast<Part::Part2DObject*>(Sketch.getValue())->Support.getValue();
Part::Feature* SupportObject = NULL;
if (SupportLink && SupportLink->getTypeId().isDerivedFrom(Part::Feature::getClassTypeId()))