From: markt Date: Fri, 27 Nov 2009 18:01:12 +0000 (+0000) Subject: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=48285 X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=40368984fcf7dac3f666db5a8e2e24eff7d59d81;p=tomcat7.0 Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=48285 Add handling of Async dispatcher types git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@884926 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/java/org/apache/catalina/core/ApplicationFilterFactory.java b/java/org/apache/catalina/core/ApplicationFilterFactory.java index 8dc705f12..57fbf9866 100644 --- a/java/org/apache/catalina/core/ApplicationFilterFactory.java +++ b/java/org/apache/catalina/core/ApplicationFilterFactory.java @@ -354,6 +354,12 @@ public final class ApplicationFilterFactory { } break; } + case ASYNC : { + if ((filterMap.getDispatcherMapping() & FilterMap.ASYNC) > 0) { + return true; + } + break; + } } return false; } diff --git a/java/org/apache/catalina/deploy/FilterMap.java b/java/org/apache/catalina/deploy/FilterMap.java index 3239a0deb..d22278d8b 100644 --- a/java/org/apache/catalina/deploy/FilterMap.java +++ b/java/org/apache/catalina/deploy/FilterMap.java @@ -52,6 +52,7 @@ public class FilterMap implements Serializable { public static final int FORWARD = 2; public static final int INCLUDE = 4; public static final int REQUEST = 8; + public static final int ASYNC = 16; // represents nothing having been set. This will be seen // as equal to a REQUEST @@ -134,22 +135,7 @@ public class FilterMap implements Serializable { /** * * This method will be used to set the current state of the FilterMap - * representing the state of when filters should be applied: - * - * ERROR - * FORWARD - * FORWARD_ERROR - * INCLUDE - * INCLUDE_ERROR - * INCLUDE_ERROR_FORWARD - * REQUEST - * REQUEST_ERROR - * REQUEST_ERROR_INCLUDE - * REQUEST_ERROR_FORWARD_INCLUDE - * REQUEST_INCLUDE - * REQUEST_FORWARD, - * REQUEST_FORWARD_INCLUDE - * + * representing the state of when filters should be applied. */ public void setDispatcher(String dispatcherString) { String dispatcher = dispatcherString.toUpperCase(); @@ -166,6 +152,9 @@ public class FilterMap implements Serializable { } else if (dispatcher.equals(DispatcherType.ERROR.name())) { // apply ERROR to the global dispatcherMapping. dispatcherMapping |= ERROR; + } else if (dispatcher.equals(DispatcherType.ASYNC.name())) { + // apply ERROR to the global dispatcherMapping. + dispatcherMapping |= ASYNC; } }