Make the fix for https://issues.apache.org/bugzilla/show_bug.cgi?id=50394 done in...
authorkkolinko <kkolinko@13f79535-47bb-0310-9956-ffa450edef68>
Fri, 26 Aug 2011 12:24:56 +0000 (12:24 +0000)
committerkkolinko <kkolinko@13f79535-47bb-0310-9956-ffa450edef68>
Fri, 26 Aug 2011 12:24:56 +0000 (12:24 +0000)
No functional change.

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

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

index 8692b00..294c5b1 100644 (file)
@@ -615,7 +615,10 @@ public class InternalAprInputBuffer extends AbstractInputBuffer<Long> {
             } else {
                 if ((-nRead) == Status.ETIMEDOUT || (-nRead) == Status.TIMEUP) {
                     throw new SocketTimeoutException(sm.getString("iib.failedread"));
-                } else if (nRead != 0) {
+                } else if (nRead == 0) {
+                    // APR_STATUS_IS_EOF, since native 1.1.22
+                    return false;
+                } else {
                     throw new IOException(sm.getString("iib.failedread"));
                 }
             }