Revert, if Content-Length: <some large value> is an acceptable work around
authorfhanik <fhanik@13f79535-47bb-0310-9956-ffa450edef68>
Sat, 17 Jun 2006 00:12:20 +0000 (00:12 +0000)
committerfhanik <fhanik@13f79535-47bb-0310-9956-ffa450edef68>
Sat, 17 Jun 2006 00:12:20 +0000 (00:12 +0000)
git-svn-id: https://svn.apache.org/repos/asf/tomcat/tc6.0.x/trunk@414965 13f79535-47bb-0310-9956-ffa450edef68

java/org/apache/coyote/http11/Http11AprProcessor.java
java/org/apache/coyote/http11/InternalAprInputBuffer.java

index 6c31811..841e81f 100644 (file)
@@ -743,19 +743,9 @@ public class Http11AprProcessor implements ActionHook {
         \r
         try {\r
             rp.setStage(org.apache.coyote.Constants.STAGE_SERVICE);\r
-            int data = inputBuffer.readSocketData();\r
-            if ( data > 0 ) {\r
-                int contentLength = request.getContentLength();\r
-                if (contentLength>=0) request.setContentLength(contentLength + data);\r
-                for (int i=0; i<inputBuffer.activeFilters.length; i++) {\r
-                    //this resets the remaining flag and the content length on the filter\r
-                    //if we don't do this, then request.getInputStream.read will return 0\r
-                    if (inputBuffer.activeFilters[i]!=null) inputBuffer.activeFilters[i].setRequest(request);\r
-                }\r
-                error = !adapter.event(request, response, error);\r
-                if (request.getAttribute("org.apache.tomcat.comet") == null) {\r
-                    comet = false;\r
-                }\r
+            error = !adapter.event(request, response, error);\r
+            if (request.getAttribute("org.apache.tomcat.comet") == null) {\r
+                comet = false;\r
             }\r
         } catch (InterruptedIOException e) {\r
             error = true;\r
index fffde33..699e2f8 100644 (file)
@@ -350,17 +350,6 @@ public class InternalAprInputBuffer implements InputBuffer {
         }\r
 \r
     }\r
-    \r
-    public int readSocketData() {\r
-        bbuf.clear();\r
-        int nRead = Socket.recvbbt(socket, 0, buf.length - lastValid, readTimeout);\r
-        if (nRead > 0) {\r
-            bbuf.limit(nRead);\r
-            bbuf.get(buf, pos, nRead);\r
-            lastValid = pos + nRead;\r
-        }\r
-        return nRead>=0?nRead:-1;\r
-    }\r
 \r
 \r
     /**\r