Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=51630
authormarkt <markt@13f79535-47bb-0310-9956-ffa450edef68>
Mon, 3 Oct 2011 19:50:09 +0000 (19:50 +0000)
committermarkt <markt@13f79535-47bb-0310-9956-ffa450edef68>
Mon, 3 Oct 2011 19:50:09 +0000 (19:50 +0000)
Correct bug in async examples. Remove unnecessary call to
AsyncContext.complete() that triggered an ISE.

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

webapps/examples/WEB-INF/classes/async/Async0.java

index 93dd0a0..4861a2b 100644 (file)
@@ -39,7 +39,6 @@ public class Async0 extends HttpServlet {
             log.info("Received dispatch, completing on the worker thread.");
             log.info("After complete called started:"+req.isAsyncStarted());
             resp.getWriter().write("Async dispatch worked:+"+System.currentTimeMillis()+"\n");
-            req.getAsyncContext().complete();
         } else {
             resp.setContentType("text/plain");
             final AsyncContext actx = req.startAsync();