help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: base64-encoding-region does not work on multibyte character


From: Stefan Monnier
Subject: Re: base64-encoding-region does not work on multibyte character
Date: Mon, 09 Apr 2012 22:43:52 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.94 (gnu/linux)

> I get error "Multibyte character in data for base64 encoding" when I
> try to base64 encoding some utf-8 text.

base64 is an encoding which applies to *bytes*, not chars.  So you first
need to encode your sequence of chars into a sequence of bytes using
some coding-system.  I.e. apply `encode-coding-string/region'.
And after that, you can use base64-encode-string/region.


        Stefan


reply via email to

[Prev in Thread] Current Thread [Next in Thread]