Return-Path: X-Original-To: apmail-hc-commits-archive@www.apache.org Delivered-To: apmail-hc-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 6DD6BC5A4 for ; Wed, 6 Jun 2012 19:58:14 +0000 (UTC) Received: (qmail 6228 invoked by uid 500); 6 Jun 2012 19:58:14 -0000 Delivered-To: apmail-hc-commits-archive@hc.apache.org Received: (qmail 6176 invoked by uid 500); 6 Jun 2012 19:58:14 -0000 Mailing-List: contact commits-help@hc.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "HttpComponents Project" Delivered-To: mailing list commits@hc.apache.org Received: (qmail 6167 invoked by uid 99); 6 Jun 2012 19:58:14 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 06 Jun 2012 19:58:14 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 06 Jun 2012 19:58:11 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id E3D562388A4A for ; Wed, 6 Jun 2012 19:57:50 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1347082 - in /httpcomponents/httpcore/trunk: RELEASE_NOTES.txt httpcore/src/main/java/org/apache/http/entity/ContentType.java Date: Wed, 06 Jun 2012 19:57:50 -0000 To: commits@hc.apache.org From: olegk@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20120606195750.E3D562388A4A@eris.apache.org> Author: olegk Date: Wed Jun 6 19:57:50 2012 New Revision: 1347082 URL: http://svn.apache.org/viewvc?rev=1347082&view=rev Log: HTTPCORE-299: ContentType should rely on Charset#name() instead of Charset#toString() for building header value Modified: httpcomponents/httpcore/trunk/RELEASE_NOTES.txt httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/entity/ContentType.java Modified: httpcomponents/httpcore/trunk/RELEASE_NOTES.txt URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/RELEASE_NOTES.txt?rev=1347082&r1=1347081&r2=1347082&view=diff ============================================================================== --- httpcomponents/httpcore/trunk/RELEASE_NOTES.txt (original) +++ httpcomponents/httpcore/trunk/RELEASE_NOTES.txt Wed Jun 6 19:57:50 2012 @@ -1,6 +1,10 @@ Changes since 4.2 ------------------- +* [HTTPCORE-299] ContentType should rely on Charset#name() instead of Charset#toString() + for building header value. + Contributed by Oleg Kalnichevski + * [HTTPCORE-263] Under rare circumstances incorrectly delineated or garbled HTTP message can cause an IndexOutOfBoundsException in AbstractSessionInputBuffer#readLine() Contributed by Michael Pujos Modified: httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/entity/ContentType.java URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/entity/ContentType.java?rev=1347082&r1=1347081&r2=1347082&view=diff ============================================================================== --- httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/entity/ContentType.java (original) +++ httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/entity/ContentType.java Wed Jun 6 19:57:50 2012 @@ -115,7 +115,7 @@ public final class ContentType { buf.append(this.mimeType); if (this.charset != null) { buf.append("; charset="); - buf.append(this.charset); + buf.append(this.charset.name()); } return buf.toString(); }