Update the embedded copy of the expat XML parser to 2.1.0. It brings
with it a vareity of bug fixes, both security and behavior. See
http://www.libexpat.org/ for the list.
NOTE: I already backported the expat hash randomization fix in March.
Fixes issue #14340.
diff --git a/Modules/expat/xmltok_impl.c b/Modules/expat/xmltok_impl.c
index f793a6b..9c2895b 100644
--- a/Modules/expat/xmltok_impl.c
+++ b/Modules/expat/xmltok_impl.c
@@ -2,6 +2,9 @@
See the file COPYING for copying permission.
*/
+/* This file is included! */
+#ifdef XML_TOK_IMPL_C
+
#ifndef IS_INVALID_CHAR
#define IS_INVALID_CHAR(enc, ptr, n) (0)
#endif
@@ -882,7 +885,7 @@
const char **nextTokPtr)
{
if (ptr == end)
- return -XML_TOK_PERCENT;
+ return XML_TOK_PARTIAL;
switch (BYTE_TYPE(enc, ptr)) {
CHECK_NMSTRT_CASES(enc, ptr, end, nextTokPtr)
case BT_S: case BT_LF: case BT_CR: case BT_PERCNT:
@@ -1777,3 +1780,4 @@
#undef CHECK_NMSTRT_CASE
#undef CHECK_NMSTRT_CASES
+#endif /* XML_TOK_IMPL_C */