mirror of
git://git.sv.gnu.org/nano.git
synced 2024-11-25 22:29:42 +03:00
files: when Mac format has been detected, stay with it
This fixes https://savannah.gnu.org/bugs/?60382.
Bug existed since commit 09b919a6
from three weeks ago.
This commit is contained in:
parent
018a8e12ca
commit
8db42023bb
@ -699,7 +699,7 @@ void read_file(FILE *f, int fd, const char *filename, bool undoable)
|
|||||||
format = DOS_FILE;
|
format = DOS_FILE;
|
||||||
len--;
|
len--;
|
||||||
}
|
}
|
||||||
} else if ((num_lines == 0 || format == 2) &&
|
} else if ((num_lines == 0 || format == MAC_FILE) &&
|
||||||
len > 0 && buf[len - 1] == '\r' && !ISSET(NO_CONVERT)) {
|
len > 0 && buf[len - 1] == '\r' && !ISSET(NO_CONVERT)) {
|
||||||
format = MAC_FILE;
|
format = MAC_FILE;
|
||||||
len--;
|
len--;
|
||||||
|
Loading…
Reference in New Issue
Block a user