You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hc.apache.org by as...@apache.org on 2009/06/05 11:35:45 UTC
svn commit: r781964 -
/httpcomponents/httpcore/trunk/httpcore-nio/src/examples/org/apache/http/examples/nio/NHttpFileServer.java
Author: asankha
Date: Fri Jun 5 09:35:45 2009
New Revision: 781964
URL: http://svn.apache.org/viewvc?rev=781964&view=rev
Log:
fix IllegalArgumentException from ByteBuffer.limit() when using the ChunkDecoder
Modified:
httpcomponents/httpcore/trunk/httpcore-nio/src/examples/org/apache/http/examples/nio/NHttpFileServer.java
Modified: httpcomponents/httpcore/trunk/httpcore-nio/src/examples/org/apache/http/examples/nio/NHttpFileServer.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore-nio/src/examples/org/apache/http/examples/nio/NHttpFileServer.java?rev=781964&r1=781963&r2=781964&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore-nio/src/examples/org/apache/http/examples/nio/NHttpFileServer.java (original)
+++ httpcomponents/httpcore/trunk/httpcore-nio/src/examples/org/apache/http/examples/nio/NHttpFileServer.java Fri Jun 5 09:35:45 2009
@@ -217,7 +217,7 @@
fileChannel, idx, Long.MAX_VALUE);
} else {
transferred = fileChannel.transferFrom(
- new ContentDecoderChannel(decoder), idx, Long.MAX_VALUE);
+ new ContentDecoderChannel(decoder), idx, Integer.MAX_VALUE);
}
if(transferred > 0)