Fix bug 42727. Handle request lines that are exact multiples of 4096 in length.
authormarkt <markt@13f79535-47bb-0310-9956-ffa450edef68>
Thu, 17 Jul 2008 22:09:18 +0000 (22:09 +0000)
committermarkt <markt@13f79535-47bb-0310-9956-ffa450edef68>
Thu, 17 Jul 2008 22:09:18 +0000 (22:09 +0000)
Patch provided by Will Pugh.

git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@677759 13f79535-47bb-0310-9956-ffa450edef68

java/org/apache/catalina/connector/CoyoteReader.java

index d3584e9..9b51ac4 100644 (file)
@@ -153,7 +153,7 @@ public class CoyoteReader
             while ((pos < MAX_LINE_LENGTH) && (end < 0)) {
                 int nRead = read(lineBuffer, pos, MAX_LINE_LENGTH - pos);
                 if (nRead < 0) {
-                    if (pos == 0) {
+                    if (pos == 0 && aggregator == null) {
                         return null;
                     }
                     end = pos;