https://issues.apache.org/bugzilla/show_bug.cgi?id=46713
Summary: path attribute in context tag of context xml's ignored
Product: Tomcat 6
Version: 6.0.18
Platform: All
OS/Version: All
Status: NEW
Keywords: PatchAvailable
Severity: normal
Priority: P2
Component: Catalina
AssignedTo: [email protected]
ReportedBy: [email protected]
If a path attribute is set inside the context tag in context xml's it is
ignored. Instead the path is set to "/" + <name of the context xml file minus
xml extension>.
While it nice that even pathes with '/' can be encoded in the file name by
replacing '/' with '#' it is very confusing that an existing path attribute is
simply ignored. The following patch against trunk should fix this:
Index: java/org/apache/catalina/startup/HostConfig.java
===================================================================
--- java/org/apache/catalina/startup/HostConfig.java (Revision 744499)
+++ java/org/apache/catalina/startup/HostConfig.java (Arbeitskopie)
@@ -601,7 +601,9 @@
((Lifecycle) context).addLifecycleListener(listener);
}
context.setConfigFile(contextXml.getAbsolutePath());
- context.setPath(contextPath);
+ if (context.getPath() == null) {
+ context.setPath(contextPath);
+ }
// Add the associated docBase to the redeployed list if it's a WAR
boolean isExternalWar = false;
boolean isExternal = false;
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]