From 8b9b11a03827e2622647ac1cbce9a00f08d3a0a8 Mon Sep 17 00:00:00 2001 From: antelder Date: Mon, 26 Oct 2009 09:09:51 +0000 Subject: Update to remove the entire serelet path if the path starts with it so that servelts registered with the Tuscany ServletHost get the correct value. (Not sure i completely understand the rest of the code in that method, does anyone else?) git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@829732 13f79535-47bb-0310-9956-ffa450edef68 --- .../org/apache/tuscany/sca/host/webapp/WebAppRequestDispatcher.java | 3 +++ 1 file changed, 3 insertions(+) (limited to 'java/sca/modules/host-webapp/src') diff --git a/java/sca/modules/host-webapp/src/main/java/org/apache/tuscany/sca/host/webapp/WebAppRequestDispatcher.java b/java/sca/modules/host-webapp/src/main/java/org/apache/tuscany/sca/host/webapp/WebAppRequestDispatcher.java index f14dfac58b..76cce939ad 100644 --- a/java/sca/modules/host-webapp/src/main/java/org/apache/tuscany/sca/host/webapp/WebAppRequestDispatcher.java +++ b/java/sca/modules/host-webapp/src/main/java/org/apache/tuscany/sca/host/webapp/WebAppRequestDispatcher.java @@ -86,6 +86,9 @@ class WebAppRequestDispatcher implements RequestDispatcher { * Remove any path suffix thats part of the Servlet context path */ protected String fiddlePath(String path, String servletPath) { + if (path.startsWith(servletPath)) { + return path.substring(servletPath.length()); + } StringTokenizer st = new StringTokenizer(path, "/"); if (st.countTokens() == 1) { return path; -- cgit v1.2.3