[Lxml-checkins] r48750 - lxml/trunk/src/lxml

scoder at codespeak.net scoder at codespeak.net
Sat Nov 17 12:52:19 CET 2007


Author: scoder
Date: Sat Nov 17 12:52:19 2007
New Revision: 48750

Modified:
   lxml/trunk/src/lxml/iterparse.pxi
Log:
cleanup

Modified: lxml/trunk/src/lxml/iterparse.pxi
==============================================================================
--- lxml/trunk/src/lxml/iterparse.pxi	(original)
+++ lxml/trunk/src/lxml/iterparse.pxi	Sat Nov 17 12:52:19 2007
@@ -348,7 +348,6 @@
         cdef _IterparseContext context
         cdef xmlparser.xmlParserCtxt* pctxt
         cdef int error
-        cdef char* c_filename
         if self._source is None:
             raise StopIteration
 
@@ -383,6 +382,7 @@
                 break
         if error != 0:
             self._source = None
+            del context._events[:]
             _raiseParseError(pctxt, self._filename, context._error_log)
         if python.PyList_GET_SIZE(context._events) == 0:
             self.root = context._root


More information about the lxml-checkins mailing list