Author: markt
Date: Thu Jan 5 15:07:19 2017
New Revision: 1777471
URL: http://svn.apache.org/viewvc?rev=1777471&view=rev
Log:
Fix https://bz.apache.org/bugzilla/show_bug.cgi?id=60409
When unable to complete sendfile request, ensure the Processor will be added to
the cache only once.
Modified:
tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java
tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml
Modified: tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java
URL:
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java?rev=1777471&r1=1777470&r2=1777471&view=diff
==============================================================================
--- tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java
(original)
+++ tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java Thu
Jan 5 15:07:19 2017
@@ -1413,11 +1413,15 @@ public class NioEndpoint extends Abstrac
}
}catch ( IOException x ) {
if ( log.isDebugEnabled() ) log.debug("Unable to complete
sendfile request:", x);
- cancelledKey(sk,SocketStatus.ERROR,false);
+ if (!calledByProcessor) {
+ cancelledKey(sk,SocketStatus.ERROR,false);
+ }
return SendfileState.ERROR;
}catch ( Throwable t ) {
log.error("",t);
- cancelledKey(sk, SocketStatus.ERROR, false);
+ if (!calledByProcessor) {
+ cancelledKey(sk, SocketStatus.ERROR, false);
+ }
return SendfileState.ERROR;
}
}
Modified: tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml
URL:
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml?rev=1777471&r1=1777470&r2=1777471&view=diff
==============================================================================
--- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Thu Jan 5 15:07:19 2017
@@ -125,6 +125,10 @@
when configured with an address of <code>0.0.0.0</code> or
<code>::</code>. (markt)
</fix>
+ <fix>
+ <bug>60409</bug>: When unable to complete sendfile request, ensure the
+ Processor will be added to the cache only once. (markt/violetagg)
+ </fix>
</changelog>
</subsection>
<subsection name="Jasper">
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]