mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2024-11-21 06:55:35 +00:00
Use emacs-internal coding system to read/write Elisp data
* lisp/org-persist.el (org-persist--read-elisp-file): (org-persist--write-elisp-file): * lisp/ox.el (org-export-async-start): Suggested by Emacs maintainer. Link: https://list.orgmode.org/861q4zy0va.fsf@gnu.org/
This commit is contained in:
parent
1387e36135
commit
be39e61c4e
@ -416,7 +416,7 @@ FORMAT and ARGS are passed to `message'."
|
||||
(defun org-persist--read-elisp-file (&optional buffer-or-file)
|
||||
"Read elisp data from BUFFER-OR-FILE or current buffer."
|
||||
(let (;; UTF-8 is explicitly used in `org-persist--write-elisp-file'.
|
||||
(coding-system-for-read 'utf-8)
|
||||
(coding-system-for-read 'emacs-internal)
|
||||
(buffer-or-file (or buffer-or-file (current-buffer))))
|
||||
(with-temp-buffer
|
||||
(if (bufferp buffer-or-file)
|
||||
@ -464,7 +464,7 @@ FORMAT and ARGS are passed to `message'."
|
||||
(let ((write-region-inhibit-fsync t)
|
||||
;; We set UTF-8 here and in `org-persist--read-elisp-file'
|
||||
;; to avoid the overhead from `find-auto-coding'.
|
||||
(coding-system-for-write 'utf-8)
|
||||
(coding-system-for-write 'emacs-internal)
|
||||
(print-circle (not no-circular))
|
||||
print-level
|
||||
print-length
|
||||
|
@ -6671,7 +6671,7 @@ and `org-export-to-file' for more specialized functions."
|
||||
(with-temp-message "Initializing asynchronous export process"
|
||||
(let ((copy-fun (org-element--generate-copy-script (current-buffer)))
|
||||
(temp-file (make-temp-file "org-export-process")))
|
||||
(let ((coding-system-for-write 'utf-8-emacs-unix))
|
||||
(let ((coding-system-for-write 'emacs-internal))
|
||||
(write-region
|
||||
;; Null characters (from variable values) are inserted
|
||||
;; within the file. As a consequence, coding system for
|
||||
|
Loading…
Reference in New Issue
Block a user