From 3a7da561cc69594b4a61306241e1ca330a17fbc6 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Sat, 27 Nov 2010 19:31:12 -0700 Subject: [PATCH] Fix regression taht broke RTF conversion on some linux systems --- src/calibre/ebooks/rtf/input.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/calibre/ebooks/rtf/input.py b/src/calibre/ebooks/rtf/input.py index 75c839eb83..57903a6711 100644 --- a/src/calibre/ebooks/rtf/input.py +++ b/src/calibre/ebooks/rtf/input.py @@ -292,7 +292,8 @@ class RTFInput(InputFormatPlugin): # Replace newlines inserted by the 'empty_paragraphs' option in rtf2xml with html blank lines if not getattr(self.options, 'remove_paragraph_spacing', False): res = re.sub('\s*', '', res) - res = re.sub('(?<=\n)\n{2}', u'

\u00a0

\n', res) + res = re.sub('(?<=\n)\n{2}', + u'

\u00a0

\n'.encode('utf-8'), res) if self.options.preprocess_html: preprocessor = PreProcessor(self.options, log=getattr(self, 'log', None)) res = preprocessor(res)