[sysadmin-bin] ftpadmin: fix unicode error when DOAP file contains utf-8 chars
- From: Olav Vitters <ovitters src gnome org>
- To: gnome-sysadmin gnome org,commits-list gnome org
- Subject: [sysadmin-bin] ftpadmin: fix unicode error when DOAP file contains utf-8 chars
- Date: Tue, 3 May 2011 19:42:49 +0000 (UTC)
commit a9753793e898df1d148c9c05c41855cafe3ca411
Author: Olav Vitters <olav vitters nl>
Date: Tue May 3 21:42:39 2011 +0200
ftpadmin: fix unicode error when DOAP file contains utf-8 chars
ftpadmin | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/ftpadmin b/ftpadmin
index 76b4e5c..83f9501 100755
--- a/ftpadmin
+++ b/ftpadmin
@@ -1029,7 +1029,7 @@ Install %s? [Y/n]""" % self.module,
modulename = self.moduleinfo.get_one_from_doap('name', self.module)
self._print_header(mail, "About %s" % (modulename or self.module))
print >>mail, ""
- for paragraph in desc.split("\n\n"):
+ for paragraph in desc.encode('utf-8').split("\n\n"):
if "\n" in paragraph: paragraph = re_whitespace.sub(" ", paragraph)
print >>mail, textwrap.fill(paragraph)
print >>mail, ""
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]