Re: patch: Accept-Charset: utf-8,*;q=0.8
On Thu, Apr 17, 2008 at 04:57:48PM +0000, corvid wrote:
It is good for dillo to state its preference for UTF-8 over ISO-8859-1.
Also, the RFC says that not mentioning '*' puts dillo in theoretical danger of receiving 406 Not Acceptable.
Committed, assuming: "Accept-Charset: utf-8,*;q=0.8\r\n" means dillo2 leaves the door open to also receive iso-8859-1. -- Cheers Jorge.-
--- dillo2/src/IO/http.c 2008-04-11 19:48:51.000000000 +0000 +++ dillo2-cur/src/IO/http.c 2008-04-17 16:17:17.000000000 +0000 @@ -236,7 +236,7 @@ Dstr *a_Http_make_query_str(const DilloU query, "POST %s HTTP/1.1\r\n" "Connection: close\r\n" - "Accept-Charset: utf-8, iso-8859-1\r\n" + "Accept-Charset: utf-8,*;q=0.8\r\n" "Accept-Encoding: gzip\r\n" "Host: %s%s\r\n" "%s" @@ -258,7 +258,7 @@ Dstr *a_Http_make_query_str(const DilloU "GET %s HTTP/1.1\r\n" "%s" "Connection: close\r\n" - "Accept-Charset: utf-8, iso-8859-1\r\n" + "Accept-Charset: utf-8,*;q=0.8\r\n" "Accept-Encoding: gzip\r\n" "Host: %s%s\r\n" "%s"
Jorge wrote:
Committed, assuming:
"Accept-Charset: utf-8,*;q=0.8\r\n"
means dillo2 leaves the door open to also receive iso-8859-1.
Yes. Here's what the RFC says: The special value "*", if present in the Accept-Charset field, matches every character set (including ISO-8859-1) which is not mentioned elsewhere in the Accept-Charset field. If no "*" is present in an Accept-Charset field, then all character sets not explicitly mentioned get a quality value of 0, except for ISO-8859-1, which gets a quality value of 1 if not explicitly mentioned.
On Sat, Apr 26, 2008 at 04:56:45PM +0000, corvid wrote:
Jorge wrote:
Committed, assuming:
"Accept-Charset: utf-8,*;q=0.8\r\n"
means dillo2 leaves the door open to also receive iso-8859-1.
Yes. Here's what the RFC says:
The special value "*", if present in the Accept-Charset field, matches every character set (including ISO-8859-1) which is not mentioned elsewhere in the Accept-Charset field. If no "*" is present in an Accept-Charset field, then all character sets not explicitly mentioned get a quality value of 0, except for ISO-8859-1, which gets a quality value of 1 if not explicitly mentioned.
OK. -- Cheers Jorge.-
participants (2)
-
corvid@lavabit.com
-
jcid@dillo.org