diff --git a/src/App/Document.cpp b/src/App/Document.cpp index 67d9490c5f..f91f464058 100644 --- a/src/App/Document.cpp +++ b/src/App/Document.cpp @@ -537,6 +537,10 @@ void Document::exportGraphviz(std::ostream& out) const //setup the origin if available if(cs->hasExtension(App::OriginGroupExtension::getExtensionClassTypeId())) { auto origin = cs->getExtensionByType()->Origin.getValue(); + if (!origin) { + std::cerr << "Origin feature not found" << std::endl; + return; + } auto& osub = sub.create_subgraph(); GraphList[origin] = &osub; get_property(osub, graph_name) = getClusterName(origin);