[Zpt] CVS: Packages/TAL - nsgmllib.py:1.10

guido@digicool.com guido@digicool.com
Fri, 16 Mar 2001 06:55:11 -0500 (EST)


Update of /cvs-repository/Packages/TAL
In directory korak:/tmp/cvs-serv18355

Modified Files:
	nsgmllib.py 
Log Message:
Oops.  Fix two bugs in the handling of character and entity
references, introduced by the line number / offset code.



--- Updated File nsgmllib.py in package Packages/TAL --
--- nsgmllib.py	2001/03/15 22:53:45	1.9
+++ nsgmllib.py	2001/03/16 11:55:11	1.10
@@ -174,7 +174,7 @@
                     name = match.group(1)
                     self.handle_charref(name)
                     k = match.end(0)
-                    if rawdata[i-1] != ';':
+                    if rawdata[k-1] != ';':
                         k = k-1
                     i = self.updatepos(i, k)
                     continue
@@ -183,7 +183,7 @@
                     name = match.group(1)
                     self.handle_entityref(name)
                     k = match.end(0)
-                    if rawdata[i-1] != ';':
+                    if rawdata[k-1] != ';':
                         k = k-1
                     i = self.updatepos(i, k)
                     continue