You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by mt...@apache.org on 2007/02/26 20:09:42 UTC

svn commit: r511951 - /tomcat/connectors/trunk/jk/native/apache-2.0/mod_jk.c

Author: mturk
Date: Mon Feb 26 11:09:41 2007
New Revision: 511951

URL: http://svn.apache.org/viewvc?view=rev&rev=511951
Log:
Use r->filename because mod_dir or mod_alias could already set that

Modified:
    tomcat/connectors/trunk/jk/native/apache-2.0/mod_jk.c

Modified: tomcat/connectors/trunk/jk/native/apache-2.0/mod_jk.c
URL: http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/apache-2.0/mod_jk.c?view=diff&rev=511951&r1=511950&r2=511951
==============================================================================
--- tomcat/connectors/trunk/jk/native/apache-2.0/mod_jk.c (original)
+++ tomcat/connectors/trunk/jk/native/apache-2.0/mod_jk.c Mon Feb 26 11:09:41 2007
@@ -2799,7 +2799,7 @@
                                                       &jk_module);
 
         if (conf) {
-            const char *worker;
+            const char *worker;            
             if ((r->handler != NULL) && (!strcmp(r->handler, JK_HANDLER))) {
                 /* Somebody already set the handler, probably manual config
                  * or "native" configuration, no need for extra overhead
@@ -2959,16 +2959,6 @@
                     }
                 }
             }
-            else if (conf->strip_session == JK_TRUE) {
-                char *jsessionid = strstr(r->uri, JK_PATH_SESSION_IDENTIFIER);
-                if (jsessionid) {
-                    if (JK_IS_DEBUG_LEVEL(conf->log))
-                        jk_log(conf->log, JK_LOG_DEBUG,
-                               "removing session identifier [%s] for non servlet url [%s]",
-                               jsessionid, r->uri);
-                    *jsessionid = '\0';
-                }
-            }
         }
     }
 
@@ -3019,14 +3009,23 @@
 
             }
             else if (conf->strip_session == JK_TRUE) {
-                char *jsessionid = strstr(r->uri, JK_PATH_SESSION_IDENTIFIER);
-                if (jsessionid) {
-                    if (JK_IS_DEBUG_LEVEL(conf->log))
-                        jk_log(conf->log, JK_LOG_DEBUG,
-                               "removing session identifier [%s] for non servlet url [%s]",
-                               jsessionid, r->uri);
-                    *jsessionid = '\0';
+                char *jsessionid;
+                if (r->uri) {
+                    jsessionid = strstr(r->uri, JK_PATH_SESSION_IDENTIFIER);
+                    if (jsessionid) {
+                        if (JK_IS_DEBUG_LEVEL(conf->log))
+                            jk_log(conf->log, JK_LOG_DEBUG,
+                                   "removing session identifier [%s] for non servlet url [%s]",
+                                   jsessionid, r->uri);
+                        *jsessionid = '\0';
+                    }
                 }
+                if (r->filename) {
+                    jsessionid = strstr(r->filename, JK_PATH_SESSION_IDENTIFIER);
+                    if (jsessionid)
+                        *jsessionid = '\0';
+                }
+                return DECLINED;
             }
         }
     }



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