From 3cc3fa2b6eca69ac2fbd2221ff7e3d017c79bce0 Mon Sep 17 00:00:00 2001 From: fhanik Date: Fri, 10 Aug 2007 21:07:46 +0000 Subject: [PATCH] Fix the comet recycle sync issue, will think of another solution some other time, for now this solves the problem git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@564768 13f79535-47bb-0310-9956-ffa450edef68 --- java/org/apache/coyote/http11/Http11NioProcessor.java | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/java/org/apache/coyote/http11/Http11NioProcessor.java b/java/org/apache/coyote/http11/Http11NioProcessor.java index 351dcb0ef..3b8496e49 100644 --- a/java/org/apache/coyote/http11/Http11NioProcessor.java +++ b/java/org/apache/coyote/http11/Http11NioProcessor.java @@ -989,6 +989,16 @@ public class Http11NioProcessor implements ActionHook { localName = null; remotePort = -1; localPort = -1; + //fix the synchronization scenario due to + //dual comet flags. + //while the response/request + //might already be recycled, this circumvents the bug + //and should not be an expensive operation + //however, this is a TODO and FIXME + //as it would be better coordinate the recycling of the request/response + //instead + response.recycle(); + request.recycle(); } -- 2.11.0