Explicitly set the size of the parent node if we have no children

pull/2731/head
RevoluPowered 2019-10-27 11:21:49 +00:00
parent a30936954e
commit 5d0c63391b
1 changed files with 6 additions and 0 deletions

View File

@ -313,6 +313,12 @@ namespace Assimp {
std::swap_ranges(nodes.begin(), nodes.end(), parent->mChildren);
}
else
{
parent->mNumChildren = 0;
parent->mChildren = nullptr;
}
}
catch (std::exception&) {
Util::delete_fun<aiNode> deleter;