https://bugs.gentoo.org/show_bug.cgi?id=280615 http://svn.python.org/view?view=rev&revision=74429 --- expat/xmltok_impl.c 2001-09-08 00:25:35.000000000 +0200 +++ expat/xmltok_impl.c.oden 2009-08-21 23:21:16.000000000 +0200 @@ -1728,7 +1728,7 @@ void PREFIX(updatePosition)(const ENCODI const char *end, POSITION *pos) { - while (ptr != end) { + while (ptr < end) { switch (BYTE_TYPE(enc, ptr)) { #define LEAD_CASE(n) \ case BT_LEAD ## n: \