Return-Path: Delivered-To: apmail-jakarta-tomcat-dev-archive@www.apache.org Received: (qmail 17532 invoked from network); 28 Jul 2004 16:59:21 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 28 Jul 2004 16:59:21 -0000 Received: (qmail 10808 invoked by uid 500); 28 Jul 2004 16:58:46 -0000 Delivered-To: apmail-jakarta-tomcat-dev-archive@jakarta.apache.org Received: (qmail 10568 invoked by uid 500); 28 Jul 2004 16:58:43 -0000 Mailing-List: contact tomcat-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Tomcat Developers List" Reply-To: "Tomcat Developers List" Delivered-To: mailing list tomcat-dev@jakarta.apache.org Received: (qmail 10419 invoked by uid 99); 28 Jul 2004 16:58:41 -0000 X-ASF-Spam-Status: No, hits=-0.1 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [209.237.227.194] (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.27.1) with SMTP; Wed, 28 Jul 2004 09:58:41 -0700 Received: (qmail 17000 invoked from network); 28 Jul 2004 16:58:39 -0000 Received: from localhost.hyperreal.org (HELO ?127.0.0.1?) (127.0.0.1) by localhost.hyperreal.org with SMTP; 28 Jul 2004 16:58:39 -0000 Message-ID: <4107DB3E.20306@apache.org> Date: Wed, 28 Jul 2004 18:58:38 +0200 From: Remy Maucherat User-Agent: Mozilla Thunderbird 0.7.2 (Windows/20040707) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Tomcat Developers List Subject: Re: cvs commit: jakarta-tomcat-connectors/coyote/src/java/org/apache/coyote Response.java References: <20040728004317.61647.qmail@minotaur.apache.org> <019d01c4743e$cf70b140$6c37a8c0@bbarkerxp> <4107D8F7.3010105@sun.com> In-Reply-To: <4107D8F7.3010105@sun.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Rating: localhost.hyperreal.org 1.6.2 0/1000/N X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Jan Luehe wrote: > Bill, > >> then I'd suggest simply >> doing: >> setCharacterEncoding(getCharacterEncoding()); >> in Response.getWriter (since the spec only requires that we identify the >> charset when using a Writer, and we don't really know what it is when >> using >> OutputStream). > > > The problem with this is that if you call getWriter() (with your > proposed fix) followed by getContentType(), the returned content type > will include a charset, which is against the spec of getContentType(): > > * If no character encoding has been specified, the > * charset parameter is omitted. > > This is why we need to append the default charset to the value of the > Content-Type header, if no char encoding has been specified. This is not acceptable, and is not an option, so you shouldn't be using "we need", because we won't ;) The right solution is IMO to point out the issues to the specification people. R�my --------------------------------------------------------------------- To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org