[Python-checkins] CVS: python/dist/src/Lib sgmllib.py,1.30.2.1,1.30.2.2
Anthony Baxter
anthonybaxter@users.sourceforge.net
Tue, 04 Dec 2001 22:05:11 -0800
Update of /cvsroot/python/python/dist/src/Lib
In directory usw-pr-cvs1:/tmp/cvs-serv25443
Modified Files:
Tag: release21-maint
sgmllib.py
Log Message:
backport 1.33:
Be more permissive in what is accepted as an attribute name; this makes
this module slightly more resiliant in the face of XHTML input, or just
colons in attribute names.
Index: sgmllib.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/sgmllib.py,v
retrieving revision 1.30.2.1
retrieving revision 1.30.2.2
diff -C2 -d -r1.30.2.1 -r1.30.2.2
*** sgmllib.py 2001/07/05 18:22:48 1.30.2.1
--- sgmllib.py 2001/12/05 06:05:09 1.30.2.2
***************
*** 37,41 ****
tagfind = re.compile('[a-zA-Z][-_.a-zA-Z0-9]*')
attrfind = re.compile(
! r'\s*([a-zA-Z_][-.a-zA-Z_0-9]*)(\s*=\s*'
r'(\'[^\']*\'|"[^"]*"|[-a-zA-Z0-9./:;+*%?!&$\(\)_#=~\'"]*))?')
--- 37,41 ----
tagfind = re.compile('[a-zA-Z][-_.a-zA-Z0-9]*')
attrfind = re.compile(
! r'\s*([a-zA-Z_][-:.a-zA-Z_0-9]*)(\s*=\s*'
r'(\'[^\']*\'|"[^"]*"|[-a-zA-Z0-9./:;+*%?!&$\(\)_#=~\'"]*))?')