[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master aab560f0c1: Fix saveplace.el when desktop.el restores non-ASCII b
From: |
Eli Zaretskii |
Subject: |
master aab560f0c1: Fix saveplace.el when desktop.el restores non-ASCII buffers |
Date: |
Mon, 23 May 2022 09:34:33 -0400 (EDT) |
branch: master
commit aab560f0c1955bae57cc35a71be95b5bfa2ab525
Author: Eli Zaretskii <eliz@gnu.org>
Commit: Eli Zaretskii <eliz@gnu.org>
Fix saveplace.el when desktop.el restores non-ASCII buffers
* lisp/saveplace.el (load-save-place-alist-from-file): Bind
'coding-system-for-read' to nil, so that the 'coding:' cookie in
the save-place file takes effect. (Bug#55592)
---
lisp/saveplace.el | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/lisp/saveplace.el b/lisp/saveplace.el
index 4d13ad3959..a23454b0bb 100644
--- a/lisp/saveplace.el
+++ b/lisp/saveplace.el
@@ -290,7 +290,11 @@ may have changed) back to `save-place-alist'."
;; adding hooks to it.
(with-current-buffer (get-buffer-create " *Saved Places*")
(delete-region (point-min) (point-max))
- (insert-file-contents file)
+ ;; Make sure our 'coding:' cookie in the save-place
+ ;; file will take effect, in case the caller binds
+ ;; coding-system-for-read.
+ (let (coding-system-for-read)
+ (insert-file-contents file))
(goto-char (point-min))
(setq save-place-alist
(with-demoted-errors "Error reading save-place-file: %S"
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master aab560f0c1: Fix saveplace.el when desktop.el restores non-ASCII buffers,
Eli Zaretskii <=