1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-23 10:34:07 +00:00

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.
This commit is contained in:
Eli Zaretskii 2013-04-28 21:21:01 +03:00
parent 6eaed04808
commit 9e63b4a534
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2013-04-28 Eli Zaretskii <eliz@gnu.org>
* coding.c (decode_coding_gap): Don't remove the character before
a newline unless it's a CR character. (Bug#14287)
2013-04-28 Dan Nicolaescu <dann@gnu.org>
* dispextern.h (struct face): Move enum face_underline_type

View File

@ -7774,7 +7774,7 @@ decode_coding_gap (struct coding_system *coding,
while (src_beg < src)
{
*--dst = *--src;
if (*src == '\n')
if (*src == '\n' && src > src_beg && src[-1] == '\r')
src--;
}
diff = dst - src;