[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#38587: base64-decode-region breaks encoding
From: |
Lars Ingebrigtsen |
Subject: |
bug#38587: base64-decode-region breaks encoding |
Date: |
Tue, 24 Dec 2019 16:37:15 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) |
Juri Linkov <juri@linkov.net> writes:
> Thanks, I'm using this advice.
>
> (advice-add 'base64-decode-region :after
> (lambda (beg end &optional _base64url)
> (decode-coding-region beg end buffer-file-coding-system))
> '((name . base64-decode-region-with-buffer-coding)))
I think in many cases this will work fine, but you probably will have
Emacs double-decode a lot of data, as the other code in Emacs will
normally call decode-coding-region (if you want to end up with text),
and you'll destroy the bits of your Emacs that decodes base64 data into
images and the like.
(If I read the advice correctly -- I'm not very familiar with advising
functions.)
> So I'm closing this. Not sure what could be added to documentation.
Something equivalent to what the manual has to say about it would be
nice.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
- bug#38587: base64-decode-region breaks encoding, Juri Linkov, 2019/12/12
- bug#38587: base64-decode-region breaks encoding, Lars Ingebrigtsen, 2019/12/12
- bug#38587: base64-decode-region breaks encoding, Eli Zaretskii, 2019/12/13
- bug#38587: base64-decode-region breaks encoding, Juri Linkov, 2019/12/14
- bug#38587: base64-decode-region breaks encoding, Andreas Schwab, 2019/12/15
- bug#38587: base64-decode-region breaks encoding, Juri Linkov, 2019/12/15
- bug#38587: base64-decode-region breaks encoding, Eli Zaretskii, 2019/12/16
- bug#38587: base64-decode-region breaks encoding, Juri Linkov, 2019/12/16
- bug#38587: base64-decode-region breaks encoding, Eli Zaretskii, 2019/12/17
- bug#38587: base64-decode-region breaks encoding, Juri Linkov, 2019/12/17
- bug#38587: base64-decode-region breaks encoding,
Lars Ingebrigtsen <=
- bug#38587: base64-decode-region breaks encoding, Lars Ingebrigtsen, 2019/12/24
- bug#38587: base64-decode-region breaks encoding, Andreas Schwab, 2019/12/16
- bug#38587: base64-decode-region breaks encoding, Lars Ingebrigtsen, 2019/12/17
- bug#38587: base64-decode-region breaks encoding, Eli Zaretskii, 2019/12/15
- bug#38587: base64-decode-region breaks encoding, Juri Linkov, 2019/12/15
- bug#38587: base64-decode-region breaks encoding, Eli Zaretskii, 2019/12/15