From: Georg Baum Date: Thu, 29 May 2014 12:44:38 +0000 (+0200) Subject: Fix the fix X-Git-Tag: 2.2.0alpha1~1881 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=55af9cb006563032e35fcc8bc5c8c1284c0344da;p=features.git Fix the fix MAC-style (pre-OS X) line ends were not recognized anymore --- diff --git a/lib/lyx2lyx/LyX.py b/lib/lyx2lyx/LyX.py index 93006c34e1..5ee8d5f4a8 100644 --- a/lib/lyx2lyx/LyX.py +++ b/lib/lyx2lyx/LyX.py @@ -147,7 +147,7 @@ def get_backend(textclass): def trim_eol(line): " Remove end of line char(s)." - if line[-1] != '\n': + if line[-1] != '\n' and line[-1] != '\r': # May happen for the last line of a document return line if line[-2:-1] == '\r':