On Sat, 21 Feb 2015, Mikhail Merkuryev wrote:
Thanks. The main challenge for me (and probably non-existent in Lazarus —
though I don’t know) is proper Unicode support. As far as I see, in URLs
everything you need is encode to UTF-8. And what’s, for example, in headers?
In file names? In HTTP responses?
URIs (RFC3986) and HTTP 1.1 (RFC7320+) are all US-ASCII in effect. If you need
to transfer anything else, you encode it in some way.
I know, cURL is mostly used in REST-like services because of its
flexibility, so these problems are non-existent — 128+ characters are
encoded in a predictable fashion; e.g. in my service as Unicode points in
JSON. But we xUSSR use quite a zoo of encodings (at least two one-byte
encodings are still widely used), so this is a question of pride!
JSON is for the body part of the protocols and they should be binary clean and
allow you to send whatever you please.
--
/ daniel.haxx.se
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html