diff options
| author | Eli Zaretskii | 2019-11-09 21:40:53 +0200 |
|---|---|---|
| committer | Eli Zaretskii | 2019-11-09 21:40:53 +0200 |
| commit | a1a724d73afae87b8c4daa2d64382be06fa37d0e (patch) | |
| tree | ebaf10d7acbf36c3dd7ecdf4d6e9256c7d5ce0ec | |
| parent | e73184138d5e32425cdb41e18b88bb1d8604e41f (diff) | |
| download | emacs-a1a724d73afae87b8c4daa2d64382be06fa37d0e.tar.gz emacs-a1a724d73afae87b8c4daa2d64382be06fa37d0e.zip | |
Fix an error in selecting encoding when writing zip files
* lisp/international/mule-cmds.el (select-safe-coding-system):
Treat no-conversion-multibyte that came from find-auto-coding
the same as no-conversion for the purposes of encoding. The
same logic that considers no-conversion always safe should do
the same with no-conversion-multibyte. (Bug#38155)
| -rw-r--r-- | lisp/international/mule-cmds.el | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lisp/international/mule-cmds.el b/lisp/international/mule-cmds.el index 1edf80d14c8..e4f5bb2a5f0 100644 --- a/lisp/international/mule-cmds.el +++ b/lisp/international/mule-cmds.el | |||
| @@ -896,6 +896,11 @@ It is highly recommended to fix it before writing to a file." | |||
| 896 | ;; other setting. | 896 | ;; other setting. |
| 897 | (let ((base (coding-system-base auto-cs))) | 897 | (let ((base (coding-system-base auto-cs))) |
| 898 | (unless (memq base '(nil undecided)) | 898 | (unless (memq base '(nil undecided)) |
| 899 | ;; For encoding, no-conversion-multibyte is the same as | ||
| 900 | ;; no-conversion. | ||
| 901 | (if (eq base 'no-conversion-multibyte) | ||
| 902 | (setq auto-cs 'no-conversion | ||
| 903 | base 'no-conversion)) | ||
| 899 | (setq default-coding-system (list (cons auto-cs base))) | 904 | (setq default-coding-system (list (cons auto-cs base))) |
| 900 | (setq no-other-defaults t)))) | 905 | (setq no-other-defaults t)))) |
| 901 | 906 | ||