diff options
| author | Kenichi Handa | 2002-07-26 12:07:26 +0000 |
|---|---|---|
| committer | Kenichi Handa | 2002-07-26 12:07:26 +0000 |
| commit | 1eb0bebc79c40096d0cf42bf5c0b75f2e978aeca (patch) | |
| tree | e77beae89632b81e77db6e24c510ae5c364b033e | |
| parent | 8d239c89c6580517905dfcddc02e176518a475b0 (diff) | |
| download | emacs-1eb0bebc79c40096d0cf42bf5c0b75f2e978aeca.tar.gz emacs-1eb0bebc79c40096d0cf42bf5c0b75f2e978aeca.zip | |
(revert-buffer): Before calling insert-file-contents,
kill the local variable buffer-file-coding-system.
| -rw-r--r-- | lisp/files.el | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lisp/files.el b/lisp/files.el index 549bd1de8a0..ac1712229fd 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -3305,6 +3305,12 @@ non-nil, it is called instead of rereading visited file contents." | |||
| 3305 | ;; any code conversion. | 3305 | ;; any code conversion. |
| 3306 | (if auto-save-p 'emacs-mule-unix | 3306 | (if auto-save-p 'emacs-mule-unix |
| 3307 | coding-system-for-read))) | 3307 | coding-system-for-read))) |
| 3308 | ;; This force | ||
| 3309 | ;; after-insert-file-set-buffer-file-coding-system | ||
| 3310 | ;; (called from insert-file-contents) to set | ||
| 3311 | ;; buffer-file-coding-system to a proper value. | ||
| 3312 | (kill-local-variable 'buffer-file-coding-system) | ||
| 3313 | |||
| 3308 | ;; Note that this preserves point in an intelligent way. | 3314 | ;; Note that this preserves point in an intelligent way. |
| 3309 | (if preserve-modes | 3315 | (if preserve-modes |
| 3310 | (let ((buffer-file-format buffer-file-format)) | 3316 | (let ((buffer-file-format buffer-file-format)) |