You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2008/07/03 23:26:13 UTC
svn commit: r673820 -
/tomcat/trunk/java/org/apache/catalina/core/ApplicationContext.java
Author: markt
Date: Thu Jul 3 14:26:13 2008
New Revision: 673820
URL: http://svn.apache.org/viewvc?rev=673820&view=rev
Log:
Extract the query string before we try to normalise the URI
Modified:
tomcat/trunk/java/org/apache/catalina/core/ApplicationContext.java
Modified: tomcat/trunk/java/org/apache/catalina/core/ApplicationContext.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/core/ApplicationContext.java?rev=673820&r1=673819&r2=673820&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/core/ApplicationContext.java (original)
+++ tomcat/trunk/java/org/apache/catalina/core/ApplicationContext.java Thu Jul 3 14:26:13 2008
@@ -369,10 +369,21 @@
throw new IllegalArgumentException
(sm.getString
("applicationContext.requestDispatcher.iae", path));
+
+ // Get query string
+ String queryString = null;
+ int pos = path.indexOf('?');
+ if (pos >= 0) {
+ queryString = path.substring(pos + 1);
+ path = path.substring(0, pos);
+ }
+
path = normalize(path);
if (path == null)
return (null);
+ pos = path.length();
+
// Use the thread local URI and mapping data
DispatchData dd = dispatchData.get();
if (dd == null) {
@@ -383,15 +394,6 @@
MessageBytes uriMB = dd.uriMB;
uriMB.recycle();
- // Get query string
- String queryString = null;
- int pos = path.indexOf('?');
- if (pos >= 0) {
- queryString = path.substring(pos + 1);
- } else {
- pos = path.length();
- }
-
// Use the thread local mapping data
MappingData mappingData = dd.mappingData;
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org