tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From billbar...@apache.org
Subject svn commit: r371804 - /tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/connector/InputBuffer.java
Date Tue, 24 Jan 2006 04:21:12 GMT
Author: billbarker
Date: Mon Jan 23 20:21:10 2006
New Revision: 371804

URL: http://svn.apache.org/viewcvs?rev=371804&view=rev
Log:
Fix problems with request.getReader().readLine().

Fix for Bug #38346
Submitted By: Rainer Jung (rainer dot jung at kippdata dot de)


Modified:
    tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/connector/InputBuffer.java

Modified: tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/connector/InputBuffer.java
URL: http://svn.apache.org/viewcvs/tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/connector/InputBuffer.java?rev=371804&r1=371803&r2=371804&view=diff
==============================================================================
--- tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/connector/InputBuffer.java
(original)
+++ tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/connector/InputBuffer.java
Mon Jan 23 20:21:10 2006
@@ -216,6 +216,7 @@
         if (cb.getChars().length > size) {
             cb = new CharChunk(size);
             cb.setLimit(size);
+            cb.setOptimizedWrite(false);
             cb.setCharInputChannel(this);
             cb.setCharOutputChannel(this);
         } else {
@@ -337,6 +338,9 @@
             cb.setEnd(0);
         }
 
+        int limit = bb.getLength()+cb.getStart();
+        if( cb.getLimit() < limit ) 
+	    cb.setLimit(limit);
         conv.convert(bb, cb);
         bb.setOffset(bb.getEnd());
         state = CHAR_STATE;



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message