changeset 20093:c8448efca727

(basic-save-buffer): Set buffer-file-coding-system to the coding system actually used for saving.
author Karl Heuer <kwzh@gnu.org>
date Sun, 19 Oct 1997 20:20:15 +0000
parents 2b49d1c59b83
children 583c3ace07bf
files lisp/files.el
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/files.el	Sun Oct 19 20:12:15 1997 +0000
+++ b/lisp/files.el	Sun Oct 19 20:20:15 1997 +0000
@@ -2181,6 +2181,10 @@
 		;; If a hook returned t, file is already "written".
 		;; Otherwise, write it the usual way now.
 		(setq setmodes (basic-save-buffer-1)))
+	    ;; Now we have saved the current buffer.  Let's make sure
+	    ;; that buffer-file-coding-system is fixed to what
+	    ;; actually used for saving by binding it locally.
+	    (setq buffer-file-coding-system last-coding-system-used)
 	    (setq buffer-file-number
 		  (nthcdr 10 (file-attributes buffer-file-name)))
 	    (if setmodes