In Emacs on Windows, A recovered file has an extra ^M at the end
of each line.
The following inconsistency seems to cause the trouble.
When Emacs writes out an auto-save file, Emacs doesn't set its
eol type explicitly. So CR/LF is selected for it on Windows.
On the contrary, when Emacs reads the auto-save file, Emacs
assumes that its eol type is LF.
Is this assumption necessary?
In choose_write_coding_system()@fileio.c
> if (auto_saving
> && NILP (Fstring_equal (current_buffer->filename,
> current_buffer->auto_save_file_name)))
> {
> /* We use emacs-mule for auto saving... */
> setup_coding_system (Qemacs_mule, coding);
> /* ... but with the special flag to indicate not to strip off
> leading code of eight-bit-control chars. */
> coding->flags = 1;
> goto done_setup_coding;
> }
In Finsert_file_contents()@fileio.c
> if (EQ (Vcoding_system_for_read, Qauto_save_coding))
> {
...
> coding.eol_type = CODING_EOL_LF;
...
> }
--
MIYOSHI Masanori
_______________________________________________
emacs-pretest-bug mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug