hc-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ol...@apache.org
Subject svn commit: r1584059 - in /httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http: HttpHost.java message/HeaderGroup.java
Date Wed, 02 Apr 2014 14:43:52 GMT
Author: olegk
Date: Wed Apr  2 14:43:52 2014
New Revision: 1584059

URL: http://svn.apache.org/r1584059
Log:
Use Locale.ROOT instead of Locale.US or Locale.ENGLISH for upper/lower case conversion of
locale independent textual identifiers

Modified:
    httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/HttpHost.java
    httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/message/HeaderGroup.java

Modified: httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/HttpHost.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/HttpHost.java?rev=1584059&r1=1584058&r2=1584059&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/HttpHost.java (original)
+++ httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/HttpHost.java Wed
Apr  2 14:43:52 2014
@@ -79,9 +79,9 @@ public final class HttpHost implements C
     public HttpHost(final String hostname, final int port, final String scheme) {
         super();
         this.hostname   = Args.notBlank(hostname, "Host name");
-        this.lcHostname = hostname.toLowerCase(Locale.ENGLISH);
+        this.lcHostname = hostname.toLowerCase(Locale.ROOT);
         if (scheme != null) {
-            this.schemeName = scheme.toLowerCase(Locale.ENGLISH);
+            this.schemeName = scheme.toLowerCase(Locale.ROOT);
         } else {
             this.schemeName = DEFAULT_SCHEME_NAME;
         }
@@ -126,9 +126,9 @@ public final class HttpHost implements C
         super();
         this.address = Args.notNull(address, "Inet address");
         this.hostname = address.getHostAddress();
-        this.lcHostname = this.hostname.toLowerCase(Locale.ENGLISH);
+        this.lcHostname = this.hostname.toLowerCase(Locale.ROOT);
         if (scheme != null) {
-            this.schemeName = scheme.toLowerCase(Locale.ENGLISH);
+            this.schemeName = scheme.toLowerCase(Locale.ROOT);
         } else {
             this.schemeName = DEFAULT_SCHEME_NAME;
         }

Modified: httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/message/HeaderGroup.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/message/HeaderGroup.java?rev=1584059&r1=1584058&r2=1584059&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/message/HeaderGroup.java
(original)
+++ httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/message/HeaderGroup.java
Wed Apr  2 14:43:52 2014
@@ -158,7 +158,7 @@ public class HeaderGroup implements Clon
                 valueBuffer.append(hdrs[i].getValue());
             }
 
-            return new BasicHeader(name.toLowerCase(Locale.ENGLISH), valueBuffer.toString());
+            return new BasicHeader(name.toLowerCase(Locale.ROOT), valueBuffer.toString());
         }
     }
 



Mime
View raw message