From dc437c45b69d2c163141c422d354f2c25936061f Mon Sep 17 00:00:00 2001 From: Fredrik Tolf Date: Sun, 13 May 2012 04:15:44 +0200 Subject: [PATCH] Properly use a BytesIO in XHTML outputter. --- wrw/sp/xhtml.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wrw/sp/xhtml.py b/wrw/sp/xhtml.py index 7058138..02e8dd6 100644 --- a/wrw/sp/xhtml.py +++ b/wrw/sp/xhtml.py @@ -43,7 +43,7 @@ class htmlindenter(util.indenter, htmlformatter): def forreq(req, tree): # XXX: Use proper Content-Type for clients accepting it. req.ohead["Content-Type"] = "text/html; charset=utf-8" - buf = io.StringIO() + buf = io.BytesIO() htmlindenter.output(buf, tree, doctype=(doctype, dtd), charset="utf-8") return [buf.getvalue()] -- 2.11.0