(Fwrite_region): Save and restore restriction.
authorKenichi Handa <handa@m17n.org>
Thu, 12 Jun 2003 23:23:48 +0000 (23:23 +0000)
committerKenichi Handa <handa@m17n.org>
Thu, 12 Jun 2003 23:23:48 +0000 (23:23 +0000)
src/fileio.c

index b308a4b..db5cab4 100644 (file)
@@ -4892,11 +4892,14 @@ This does code conversion according to the value of
       return val;
     }
 
+  record_unwind_protect (save_restriction_restore, save_restriction_save ());
+
   /* Special kludge to simplify auto-saving.  */
   if (NILP (start))
     {
       XSETFASTINT (start, BEG);
       XSETFASTINT (end, Z);
+      Fwiden ();
     }
 
   record_unwind_protect (build_annotations_unwind, Fcurrent_buffer ());