tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r...@apache.org
Subject cvs commit: jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core ApplicationHttpRequest.java
Date Mon, 02 Feb 2004 19:38:39 GMT
remm        2004/02/02 11:38:39

  Modified:    catalina/src/share/org/apache/catalina/core
                        ApplicationHttpRequest.java
  Log:
  - Bug 26611: forward + include was hiding the special forward
    request attributes.
  
  Revision  Changes    Path
  1.17      +12 -5     jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/ApplicationHttpRequest.java
  
  Index: ApplicationHttpRequest.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/ApplicationHttpRequest.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -r1.16 -r1.17
  --- ApplicationHttpRequest.java	26 Jan 2004 19:47:03 -0000	1.16
  +++ ApplicationHttpRequest.java	2 Feb 2004 19:38:39 -0000	1.17
  @@ -265,7 +265,14 @@
           if (pos == -1) {
               return getRequest().getAttribute(name);
           } else {
  -            return specialAttributes[pos];
  +            if ((specialAttributes[pos] == null) && (pos >= 5)) {
  +                // If it's a forward special attribute, and null, it means this
  +                // is an include, so we check the wrapped request since 
  +                // the request could have been forwarded before the include
  +                return getRequest().getAttribute(name);
  +            } else {
  +                return specialAttributes[pos];
  +            }
           }
   
       }
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org


Mime
View raw message