You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2011/09/05 13:55:31 UTC
svn commit: r1165247 -
/tomcat/trunk/java/org/apache/coyote/http11/Http11Processor.java
Author: markt
Date: Mon Sep 5 11:55:31 2011
New Revision: 1165247
URL: http://svn.apache.org/viewvc?rev=1165247&view=rev
Log:
Remove unnecessary try/catch
The methods it contained were either simple setters or already provided exactly the same exception handling
Modified:
tomcat/trunk/java/org/apache/coyote/http11/Http11Processor.java
Modified: tomcat/trunk/java/org/apache/coyote/http11/Http11Processor.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http11/Http11Processor.java?rev=1165247&r1=1165246&r2=1165247&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/coyote/http11/Http11Processor.java (original)
+++ tomcat/trunk/java/org/apache/coyote/http11/Http11Processor.java Mon Sep 5 11:55:31 2011
@@ -283,24 +283,18 @@ public class Http11Processor extends Abs
}
// Finish the handling of the request
- try {
- rp.setStage(org.apache.coyote.Constants.STAGE_ENDINPUT);
- // If we know we are closing the connection, don't drain input.
- // This way uploading a 100GB file doesn't tie up the thread
- // if the servlet has rejected it.
-
- if(error && !isAsync())
- inputBuffer.setSwallowInput(false);
- if (!isAsync())
- endRequest();
- } catch (Throwable t) {
- ExceptionUtils.handleThrowable(t);
- log.error(sm.getString("http11processor.request.finish"), t);
- // 500 - Internal Server Error
- response.setStatus(500);
- adapter.log(request, response, 0);
- error = true;
+ rp.setStage(org.apache.coyote.Constants.STAGE_ENDINPUT);
+
+ if(error && !isAsync()) {
+ // If we know we are closing the connection, don't drain
+ // input. This way uploading a 100GB file doesn't tie up the
+ // thread if the servlet has rejected it.
+ inputBuffer.setSwallowInput(false);
}
+
+ if (!isAsync())
+ endRequest();
+
try {
rp.setStage(org.apache.coyote.Constants.STAGE_ENDOUTPUT);
} catch (Throwable t) {
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org