aboutsummaryrefslogtreecommitdiffstats
path: root/src/coding.c
diff options
context:
space:
mode:
authorEli Zaretskii2013-04-28 21:21:01 +0300
committerEli Zaretskii2013-04-28 21:21:01 +0300
commit9e63b4a53403840acf3d759d8ac16475c12562e2 (patch)
tree6722b552bef57a2ea58700e3aab96892297eb57f /src/coding.c
parent6eaed04808c270230add70e61124e97a488add92 (diff)
downloademacs-9e63b4a53403840acf3d759d8ac16475c12562e2.tar.gz
emacs-9e63b4a53403840acf3d759d8ac16475c12562e2.zip
Fix bug #14287 with decoding EOL by *-dos coding systems.
src/coding.c (decode_coding_gap): Don't remove the character before a newline unless it's a CR character.
Diffstat (limited to 'src/coding.c')
-rw-r--r--src/coding.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/coding.c b/src/coding.c
index b9fb92c481b..f6664e179b7 100644
--- a/src/coding.c
+++ b/src/coding.c
@@ -7774,7 +7774,7 @@ decode_coding_gap (struct coding_system *coding,
7774 while (src_beg < src) 7774 while (src_beg < src)
7775 { 7775 {
7776 *--dst = *--src; 7776 *--dst = *--src;
7777 if (*src == '\n') 7777 if (*src == '\n' && src > src_beg && src[-1] == '\r')
7778 src--; 7778 src--;
7779 } 7779 }
7780 diff = dst - src; 7780 diff = dst - src;