]> granicus.if.org Git - libexpat/commitdiff
Fix test_ext_entity_latin1_utf16le_bom2() to work in UTF-16 builds
authorRhodri James <rhodri@kynesim.co.uk>
Tue, 22 Aug 2017 15:57:03 +0000 (16:57 +0100)
committerSebastian Pipping <sebastian@pipping.org>
Tue, 29 Aug 2017 21:13:14 +0000 (23:13 +0200)
expat/tests/runtests.c

index 8c233af3b29111dd4c6f9700f6886acb61711a63..a7e31ad6c5e2e0d8b86b9a50ff57814e769695a6 100644 (file)
@@ -6240,8 +6240,12 @@ START_TEST(test_ext_entity_latin1_utf16le_bom2)
         NULL,
         EE_PARSE_FULL_BUFFER
     };
+#ifdef XML_UNICODE
+    const XML_Char *expected = XCS("\x00ff\x00feL ");
+#else
     /* In UTF-8, y-diaeresis is 0xc3 0xbf, lowercase thorn is 0xc3 0xbe */
-    const XML_Char *expected = "\xc3\xbf\xc3\xbeL ";
+    const XML_Char *expected = XCS("\xc3\xbf\xc3\xbeL ");
+#endif
     CharData storage;