From 668db327f41afd0c127f096d5cae7c6b64af8325 Mon Sep 17 00:00:00 2001 From: PencilAmazing <16854231+PencilAmazing@users.noreply.github.com> Date: Fri, 7 Jul 2023 13:27:45 -0400 Subject: [PATCH 1/3] Fix misplaced quote --- test/models/IRR/scenegraphAnim.irr | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/models/IRR/scenegraphAnim.irr b/test/models/IRR/scenegraphAnim.irr index 1c6fd0ef4..0773f94a5 100644 --- a/test/models/IRR/scenegraphAnim.irr +++ b/test/models/IRR/scenegraphAnim.irr @@ -1,4 +1,4 @@ - + @@ -126,7 +126,7 @@ - + From d6edfad8bb6d69c0c176ba4535128f1d6ce2c8fc Mon Sep 17 00:00:00 2001 From: PencilAmazing <16854231+PencilAmazing@users.noreply.github.com> Date: Wed, 2 Aug 2023 13:52:40 -0400 Subject: [PATCH 2/3] Fix non UTF-8 xml file parsing by passing buffer size manually, as per pugixml documentation --- include/assimp/XmlParser.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/assimp/XmlParser.h b/include/assimp/XmlParser.h index 52a23bd83..4ab42ba2a 100644 --- a/include/assimp/XmlParser.h +++ b/include/assimp/XmlParser.h @@ -302,7 +302,9 @@ bool TXmlParser::parse(IOStream *stream) { stream->Read(&mData[0], 1, len); mDoc = new pugi::xml_document(); - pugi::xml_parse_result parse_result = mDoc->load_string(&mData[0], pugi::parse_full); + // load_string assumes native encoding (aka always utf-8 per build options) + //pugi::xml_parse_result parse_result = mDoc->load_string(&mData[0], pugi::parse_full); + pugi::xml_parse_result parse_result = mDoc->load_buffer(&mData[0], mData.size(), pugi::parse_full); if (parse_result.status == pugi::status_ok) { return true; } From b5032db7418e53d7497589dfe43a4d918f687a6e Mon Sep 17 00:00:00 2001 From: PencilAmazing <16854231+PencilAmazing@users.noreply.github.com> Date: Wed, 2 Aug 2023 13:57:21 -0400 Subject: [PATCH 3/3] Reverse accidental change with test file --- test/models/IRR/scenegraphAnim.irr | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/models/IRR/scenegraphAnim.irr b/test/models/IRR/scenegraphAnim.irr index 0773f94a5..2300ea18f 100644 --- a/test/models/IRR/scenegraphAnim.irr +++ b/test/models/IRR/scenegraphAnim.irr @@ -1,4 +1,4 @@ - +