From 0b02b92701fdec3f94648b95a4e0fd763b167d10 Mon Sep 17 00:00:00 2001 From: Max Vollmer Date: Fri, 15 Jun 2018 15:46:38 +0200 Subject: [PATCH] Some FBX files have Null/LimbNode attributes with an empty Properties70 element, where the Element is not NULL, but it's Compound is. The code only checked if the Element itself is NULL, thus causing a DeadlyImportError when trying to instantiate a PropertyTable for an Element that doesn't have a Compound. --- code/FBXDocumentUtil.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/FBXDocumentUtil.cpp b/code/FBXDocumentUtil.cpp index b7de8d91d..6f1e18e42 100644 --- a/code/FBXDocumentUtil.cpp +++ b/code/FBXDocumentUtil.cpp @@ -115,7 +115,7 @@ std::shared_ptr GetPropertyTable(const Document& doc, } } - if(!Properties70) { + if(!Properties70 || !Properties70->Compound()) { if(!no_warn) { DOMWarning("property table (Properties70) not found",&element); }