Coverity: Unchecked dynamic_cast

This commit is contained in:
wmayer
2020-07-20 12:37:08 +02:00
parent 1a16cde1f5
commit 45b755a596
6 changed files with 14 additions and 5 deletions

View File

@@ -177,7 +177,7 @@ std::vector<TopoDS_Shape> ShapeExtractor::getXShapes(const App::Link* xLink)
// }
Base::Placement childPlm;
if (l->getTypeId().isDerivedFrom(App::LinkElement::getClassTypeId())) {
App::LinkElement* cLinkElem = dynamic_cast<App::LinkElement*>(l);
App::LinkElement* cLinkElem = static_cast<App::LinkElement*>(l);
if (cLinkElem->hasPlacement()) {
childPlm = cLinkElem->getLinkPlacementProperty()->getValue();
}