# HG changeset patch # User Geoff Voelker <voelker@cs.washington.edu> # Date 871782541 0 # Node ID 8ece1f8d2ff6a35c870da041803e218574eca5c9 # Parent 7ef1d548462a010c46b8ffc2175c0d11cdbbade0 (Finsert_file_contents) [DOS_NT]: Set buffer_file_type according to eol conversion used on file. diff -r 7ef1d548462a -r 8ece1f8d2ff6 src/fileio.c --- a/src/fileio.c Sun Aug 17 01:45:59 1997 +0000 +++ b/src/fileio.c Sun Aug 17 01:49:01 1997 +0000 @@ -3083,16 +3083,6 @@ setup_coding_system (Fcheck_coding_system (val), &coding); } -#ifdef DOS_NT - /* Use the conversion type to determine buffer-file-type - (find-buffer-file-type is now used to help determine the - conversion). */ - if (coding.type == coding_type_no_conversion) - current_buffer->buffer_file_type = Qt; - else - current_buffer->buffer_file_type = Qnil; -#endif - fd = -1; #ifndef APOLLO @@ -3618,6 +3608,17 @@ inserted += this; } + +#ifdef DOS_NT + /* Use the conversion type to determine buffer-file-type + (find-buffer-file-type is now used to help determine the + conversion). */ + if (CODING_REQUIRE_EOL_CONVERSION (&coding)) + current_buffer->buffer_file_type = Qnil; + else + current_buffer->buffer_file_type = Qt; +#endif + /* We don't have to consider file type of MSDOS because all files are read as binary and end-of-line format has already been decoded appropriately. */