hc-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ol...@apache.org
Subject svn commit: r764911 - /httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/conn/DefaultClientConnection.java
Date Tue, 14 Apr 2009 18:19:52 GMT
Author: olegk
Date: Tue Apr 14 18:19:52 2009
New Revision: 764911

URL: http://svn.apache.org/viewvc?rev=764911&view=rev
Log:
Set session buffer size to 8192, if not set explicitly

Modified:
    httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/conn/DefaultClientConnection.java

Modified: httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/conn/DefaultClientConnection.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/conn/DefaultClientConnection.java?rev=764911&r1=764910&r2=764911&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/conn/DefaultClientConnection.java
(original)
+++ httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/conn/DefaultClientConnection.java
Tue Apr 14 18:19:52 2009
@@ -166,6 +166,9 @@
             final Socket socket,
             int buffersize,
             final HttpParams params) throws IOException {
+        if (buffersize == -1) {
+            buffersize = 8192;
+        }
         SessionInputBuffer inbuffer = super.createSessionInputBuffer(
                 socket, 
                 buffersize,
@@ -182,6 +185,9 @@
             final Socket socket,
             int buffersize,
             final HttpParams params) throws IOException {
+        if (buffersize == -1) {
+            buffersize = 8192;
+        }
         SessionOutputBuffer outbuffer = super.createSessionOutputBuffer(
                 socket,
                 buffersize,



Mime
View raw message