aboutsummaryrefslogtreecommitdiff
path: root/patches/expat/expat-2.0.1.diff
diff options
context:
space:
mode:
Diffstat (limited to 'patches/expat/expat-2.0.1.diff')
-rw-r--r--patches/expat/expat-2.0.1.diff24
1 files changed, 24 insertions, 0 deletions
diff --git a/patches/expat/expat-2.0.1.diff b/patches/expat/expat-2.0.1.diff
new file mode 100644
index 0000000..bb40f0a
--- /dev/null
+++ b/patches/expat/expat-2.0.1.diff
@@ -0,0 +1,24 @@
+diff -Naur expat-2.0.1.orig/lib/xmlparse.c expat-2.0.1/lib/xmlparse.c
+--- expat-2.0.1.orig/lib/xmlparse.c 2007-05-07 23:25:35.000000000 -0300
++++ expat-2.0.1/lib/xmlparse.c 2009-08-26 16:50:55.000000000 -0300
+@@ -2563,6 +2563,8 @@
+ (int)(dataPtr - (ICHAR *)dataBuf));
+ if (s == next)
+ break;
++ if (ps_parsing == XML_FINISHED || ps_parsing == XML_SUSPENDED)
++ break;
+ *eventPP = s;
+ }
+ }
+diff -Naur expat-2.0.1.orig/lib/xmltok_impl.c expat-2.0.1/lib/xmltok_impl.c
+--- expat-2.0.1.orig/lib/xmltok_impl.c 2006-11-26 15:34:46.000000000 -0200
++++ expat-2.0.1/lib/xmltok_impl.c 2009-08-26 16:50:57.000000000 -0300
+@@ -1744,7 +1744,7 @@
+ const char *end,
+ POSITION *pos)
+ {
+- while (ptr != end) {
++ while (ptr < end) {
+ switch (BYTE_TYPE(enc, ptr)) {
+ #define LEAD_CASE(n) \
+ case BT_LEAD ## n: \