[Expat-checkins] expat/lib xmltok_impl.c,1.13,1.14

Karl Waclawek kwaclaw at users.sourceforge.net
Wed Jun 11 16:44:05 CEST 2008


Update of /cvsroot/expat/expat/lib
In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv3569

Modified Files:
	xmltok_impl.c 
Log Message:
Fix for bug #1990430.

Index: xmltok_impl.c
===================================================================
RCS file: /cvsroot/expat/expat/lib/xmltok_impl.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -d -r1.13 -r1.14
--- xmltok_impl.c	26 Nov 2006 17:34:46 -0000	1.13
+++ xmltok_impl.c	11 Jun 2008 14:43:57 -0000	1.14
@@ -1748,6 +1748,8 @@
     switch (BYTE_TYPE(enc, ptr)) {
 #define LEAD_CASE(n) \
     case BT_LEAD ## n: \
+      if (end - ptr < n) \
+        return; \
       ptr += n; \
       break;
     LEAD_CASE(2) LEAD_CASE(3) LEAD_CASE(4)



More information about the Expat-checkins mailing list