From 9940f71578eb3dacc2f7fd595ef03ca31920a24f Mon Sep 17 00:00:00 2001 From: Rhodri James Date: Tue, 20 Jun 2017 14:58:42 +0100 Subject: [PATCH] Test parameter entity marked SYSTEM but with no ID --- expat/tests/runtests.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/expat/tests/runtests.c b/expat/tests/runtests.c index 4d7863ea..de43f96a 100644 --- a/expat/tests/runtests.c +++ b/expat/tests/runtests.c @@ -6767,6 +6767,18 @@ START_TEST(test_bad_entity_3) } END_TEST +START_TEST(test_bad_entity_4) +{ + const char *text = + "\n" + "]>\n" + ""; + expect_failure(text, XML_ERROR_SYNTAX, + "Parameter ENTITY without Public ID is not rejected"); +} +END_TEST + /* * Namespaces tests. */ @@ -12257,6 +12269,7 @@ make_suite(void) tcase_add_test(tc_basic, test_bad_entity); tcase_add_test(tc_basic, test_bad_entity_2); tcase_add_test(tc_basic, test_bad_entity_3); + tcase_add_test(tc_basic, test_bad_entity_4); suite_add_tcase(s, tc_namespace); tcase_add_checked_fixture(tc_namespace, -- 2.40.0