changeset 7130:b3e9a76134d2

(Finsert_file_contents): Fix accessing buffer_file_type since it is t or nil. Change to handle t or nil as value of find-buffer-file-type.
author Richard M. Stallman <rms@gnu.org>
date Wed, 27 Apr 1994 08:35:48 +0000
parents 6b894fba586b
children 32678633292e
files src/fileio.c
diffstat 1 files changed, 3 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/src/fileio.c	Wed Apr 27 08:27:50 1994 +0000
+++ b/src/fileio.c	Wed Apr 27 08:35:48 1994 +0000
@@ -2796,11 +2796,10 @@
     Lisp_Object code;
     code = Qnil;
     GCPRO1 (filename);
-    code = call1 (Qfind_buffer_file_type, filename);
+    current_buffer->buffer_file_type
+      = call1 (Qfind_buffer_file_type, filename);
     UNGCPRO;
-    if (XTYPE (code) == Lisp_Int) 
-      XFASTINT (current_buffer->buffer_file_type) = XFASTINT (code);
-    if (XFASTINT (current_buffer->buffer_file_type) == 0)
+    if (NILP (current_buffer->buffer_file_type))
       {
 	int reduced_size
 	  = inserted - crlf_to_lf (inserted, &FETCH_CHAR (point - 1) + 1);