[Twisted-Python] minor patch to twisted.html.web
Clark C. Evans
cce at clarkevans.com
Wed Feb 26 23:34:06 EST 2003
When calling escape, this function seems to assume that
the object being called is a string; although a user
program could do this, an explict conversion here is
more generous with the input arguments.
--- html.py.orig Wed Feb 26 23:17:00 2003
+++ html.py Wed Feb 26 23:17:39 2003
@@ -36,6 +36,7 @@
def escape(text):
"Escape a few HTML special chars with HTML entities."
+ text = str(text)
for s, h in [('&', '&'), #order is important
('<', '<'),
('>', '>'),
More information about the Twisted-Python
mailing list