[Python-checkins] CVS: python/dist/src/Lib xmllib.py,1.23,1.23.2.1
Moshe Zadka
moshez@users.sourceforge.net
Sat, 31 Mar 2001 06:26:56 -0800
Update of /cvsroot/python/python/dist/src/Lib
In directory usw-pr-cvs1:/tmp/cvs-serv23452/Lib
Modified Files:
Tag: release20-maint
xmllib.py
Log Message:
- xmllib.py - Moved clearing of "literal" flag. The flag is set in setliteral
which can be called from a start tag handler. When the corresponding end
tag is read the flag is cleared. However, it didn't get cleared when
the start tag was for an empty element of the type <tag .../>. This
modification fixes the problem.
Index: xmllib.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/xmllib.py,v
retrieving revision 1.23
retrieving revision 1.23.2.1
diff -C2 -r1.23 -r1.23.2.1
*** xmllib.py 2000/08/31 10:26:52 1.23
--- xmllib.py 2001/03/31 14:26:54 1.23.2.1
***************
*** 684,688 ****
self.handle_data(rawdata[i])
return i+1
- self.literal = 0
k = res.end(0)
if endbracket.match(rawdata, k) is None:
--- 684,687 ----
***************
*** 700,703 ****
--- 699,703 ----
# Internal -- finish processing of end tag
def finish_endtag(self, tag):
+ self.literal = 0
if not tag:
self.syntax_error('name-less end tag')