hc-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r1544989 - /httpcomponents/httpcore/trunk/httpcore/src/main/java/org/apache/http/message/HeaderGroup.java
Date Sun, 24 Nov 2013 15:06:32 GMT
Author: sebb
Date: Sun Nov 24 15:06:31 2013
New Revision: 1544989

URL: http://svn.apache.org/r1544989
Log:
Rename local variable to avoid clash with field

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

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=1544989&r1=1544988&r2=1544989&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
Sun Nov 24 15:06:31 2013
@@ -144,18 +144,18 @@ public class HeaderGroup implements Clon
      * headers by the given name are present
      */
     public Header getCondensedHeader(final String name) {
-        final Header[] headers = getHeaders(name);
+        final Header[] hdrs = getHeaders(name);
 
-        if (headers.length == 0) {
+        if (hdrs.length == 0) {
             return null;
-        } else if (headers.length == 1) {
-            return headers[0];
+        } else if (hdrs.length == 1) {
+            return hdrs[0];
         } else {
             final CharArrayBuffer valueBuffer = new CharArrayBuffer(128);
-            valueBuffer.append(headers[0].getValue());
-            for (int i = 1; i < headers.length; i++) {
+            valueBuffer.append(hdrs[0].getValue());
+            for (int i = 1; i < hdrs.length; i++) {
                 valueBuffer.append(", ");
-                valueBuffer.append(headers[i].getValue());
+                valueBuffer.append(hdrs[i].getValue());
             }
 
             return new BasicHeader(name.toLowerCase(Locale.ENGLISH), valueBuffer.toString());



Mime
View raw message