From 5ff1b7aedba2e6995344aed1cd43ce3a3e08eb45 Mon Sep 17 00:00:00 2001 From: Luca Falavigna Date: Tue, 18 Oct 2011 21:29:59 +0200 Subject: Make sure input variable is unicode --- debian/patches/series | 1 + debian/patches/unicode.patch | 16 ++++++++++++++++ 2 files changed, 17 insertions(+) create mode 100644 debian/patches/unicode.patch (limited to 'debian/patches') diff --git a/debian/patches/series b/debian/patches/series index 8717987..23715f1 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -1 +1,2 @@ no_remote_dtd.patch +unicode.patch diff --git a/debian/patches/unicode.patch b/debian/patches/unicode.patch new file mode 100644 index 0000000..5dd92aa --- /dev/null +++ b/debian/patches/unicode.patch @@ -0,0 +1,16 @@ +Description: Make sure input variable is unicode +Author: Luca Falavigna \n', '-->') + input = xml_preamble + content + xml_postamble + try: +- saxparser.parse(StringIO(input)) ++ saxparser.parse(StringIO(unicode(input))) + except: + sys.stderr.write("error in %s\n" % f) + raise -- cgit v1.2.3