From: Rhodri James Date: Tue, 22 Aug 2017 14:18:22 +0000 (+0100) Subject: Fix external_entity_param() to work for UTF-16 builds X-Git-Tag: R_2_2_5~24^2~86 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=c9f258d842ea127f35a378e261910b0a32827120;p=libexpat Fix external_entity_param() to work for UTF-16 builds --- diff --git a/expat/tests/runtests.c b/expat/tests/runtests.c index 5762b2ac..2166be95 100644 --- a/expat/tests/runtests.c +++ b/expat/tests/runtests.c @@ -4263,14 +4263,14 @@ external_entity_param(XML_Parser parser, if (ext_parser == NULL) fail("Could not create external entity parser"); - if (!strcmp(systemId, "004-1.ent")) { + if (!xcstrcmp(systemId, XCS("004-1.ent"))) { if (_XML_Parse_SINGLE_BYTES(ext_parser, text1, strlen(text1), XML_TRUE) != XML_STATUS_ERROR) fail("Inner DTD with invalid tag not rejected"); if (XML_GetErrorCode(ext_parser) != XML_ERROR_EXTERNAL_ENTITY_HANDLING) xml_failure(ext_parser); } - else if (!strcmp(systemId, "004-2.ent")) { + else if (!xcstrcmp(systemId, XCS("004-2.ent"))) { if (_XML_Parse_SINGLE_BYTES(ext_parser, text2, strlen(text2), XML_TRUE) != XML_STATUS_ERROR) fail("Invalid tag in external param not rejected");