Răsfoiți Sursa

DAE Import: Don't use SkipElement() to skip empty Text

IrrXML doesn't recognise the construction: `<author></author>` as being an empty element, and so ColladaParser::TestTextContent advances the element stream into the `</author>` element.

Use TestClosing(const char*) instead of SkipElement() to skip an empty text element.
RichardTea 6 ani în urmă
părinte
comite
59f732e10d
1 a modificat fișierele cu 1 adăugiri și 3 ștergeri
  1. 1 3
      code/Collada/ColladaParser.cpp

+ 1 - 3
code/Collada/ColladaParser.cpp

@@ -323,10 +323,8 @@ void ColladaParser::ReadMetaDataItem(StringMetaData &metadata)
             aiString aistr;
             aistr.Set(value_char);
             metadata.emplace(camel_key_str, aistr);
-            TestClosing(key_str.c_str());
         }
-        else
-            SkipElement();
+        TestClosing(key_str.c_str());
     }
     else
         SkipElement();