emacs-devel
[Top][All Lists]
Advanced

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

Re: bug#23750: 25.0.95; bug in url-retrieve or json.el


From: Dmitry Gutov
Subject: Re: bug#23750: 25.0.95; bug in url-retrieve or json.el
Date: Thu, 1 Dec 2016 02:30:15 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:50.0) Gecko/20100101 Thunderbird/50.0

On 30.11.2016 18:23, Eli Zaretskii wrote:

Since both the original issue and this one are at least indirectly
caused by jason.el, it might make sense.

Triggered, more like. JSON is a frequently-used format, but there are others. And same problems will remain when e.g. plain text is used.

I didn't mean encode-coding-string, I meant string-make-unibyte, which
for a pure-ASCII string doesn't touch the contents.

Either way, I don't think it's a great idea. Quite the opposite: by allowing the programmer to avoid calling `encode-coding-string' in more cases, we'll just make the problem in their code harder to find, until some user of that code really does need to transfer multibyte content.

Further, now that Emacs 25 is out, and we are allowed to have more breaking changes in Emacs 26, I think we should change the check at the end of url-http-create-request to just use multibyte-string-p.

Barring some unforeseen consequences, this will solidify the requirement that the caller need to deal with encoding explicitly in all cases, before passing the request body to the transport level.



reply via email to

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