Skip to content

Commit

Permalink
App: fix Origin getSubObject()
Browse files Browse the repository at this point in the history
  • Loading branch information
realthunder authored and wwmayer committed May 14, 2022
1 parent a2e99d9 commit 6340dcd
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/App/Origin.cpp
Expand Up @@ -197,7 +197,7 @@ void Origin::OriginExtension::initExtension(ExtensionContainer* obj) {
}

bool Origin::OriginExtension::extensionGetSubObject(DocumentObject *&ret, const char *subname,
PyObject **, Base::Matrix4D *, bool, int) const {
PyObject **pyobj, Base::Matrix4D *mat, bool, int depth) const {
if (!subname || subname[0] == '\0') {
return false;
}
Expand All @@ -217,6 +217,9 @@ bool Origin::OriginExtension::extensionGetSubObject(DocumentObject *&ret, const

try {
ret = obj->getOriginFeature(name.c_str());
if (!ret)
return false;
ret = ret->getSubObject(subname + name.size() + 1, pyobj, mat, true, depth+1);
return true;
}
catch (const Base::Exception& e) {
Expand Down

0 comments on commit 6340dcd

Please sign in to comment.