tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r1818438 - in /tomcat/trunk: java/org/apache/tomcat/util/net/AprEndpoint.java webapps/docs/changelog.xml
Date Sat, 16 Dec 2017 17:19:44 GMT
Author: markt
Date: Sat Dec 16 17:19:44 2017
New Revision: 1818438

URL: http://svn.apache.org/viewvc?rev=1818438&view=rev
Log:
Correct handle EOF for ServletInputStream.isReady()

Modified:
    tomcat/trunk/java/org/apache/tomcat/util/net/AprEndpoint.java
    tomcat/trunk/webapps/docs/changelog.xml

Modified: tomcat/trunk/java/org/apache/tomcat/util/net/AprEndpoint.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/net/AprEndpoint.java?rev=1818438&r1=1818437&r2=1818438&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/tomcat/util/net/AprEndpoint.java (original)
+++ tomcat/trunk/java/org/apache/tomcat/util/net/AprEndpoint.java Sat Dec 16 17:19:44 2017
@@ -2500,9 +2500,9 @@ public class AprEndpoint extends Abstrac
                 return true;
             }
 
-            fillReadBuffer(false);
+            int read = fillReadBuffer(false);
 
-            boolean isReady = socketBufferHandler.getReadBuffer().position() > 0;
+            boolean isReady = socketBufferHandler.getReadBuffer().position() > 0 || read
== -1;
             return isReady;
         }
 

Modified: tomcat/trunk/webapps/docs/changelog.xml
URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1818438&r1=1818437&r2=1818438&view=diff
==============================================================================
--- tomcat/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/trunk/webapps/docs/changelog.xml Sat Dec 16 17:19:44 2017
@@ -67,6 +67,10 @@
       <fix>
         Do not call onDataAvailable without any data to read. (remm)
       </fix>
+      <fix>
+        Correctly handle EOF when <code>ServletInputStream.isReady()</code> is
+        called. (markt)
+      </fix>
     </changelog>
   </subsection>
   <subsection name="Jasper">



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


Mime
View raw message