changeset 6177:ac2ef13dca1b

(Finsert_file_contents): If undo_list was t, leave it t. (Finsert_file_contents): Use del_range_1.
author Richard M. Stallman <rms@gnu.org>
date Thu, 03 Mar 1994 19:24:54 +0000
parents 1dbec303c87b
children ad3864a4e0bc
files src/fileio.c
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/fileio.c	Thu Mar 03 19:23:59 1994 +0000
+++ b/src/fileio.c	Thu Mar 03 19:24:54 1994 +0000
@@ -2681,8 +2681,7 @@
       /* Arrange to read only the nonmatching middle part of the file.  */
       XFASTINT (beg) = same_at_start - BEGV;
       XFASTINT (end) = st.st_size - (ZV - same_at_end);
-      /* Delete the nonmatching middle part of the buffer.  */
-      Fdelete_region (make_number (same_at_start), make_number (same_at_end));
+      del_range_1 (same_at_start, same_at_end - same_at_start, 0);
       /* Insert from the file at the proper position.  */
       SET_PT (same_at_start);
     }
@@ -2784,7 +2783,8 @@
 
   if (!NILP (visit))
     {
-      current_buffer->undo_list = Qnil;
+      if (!EQ (current_buffer->undo_list, Qt))
+	current_buffer->undo_list = Qnil;
 #ifdef APOLLO
       stat (XSTRING (filename)->data, &st);
 #endif