From c4594a7cf423c3202708a5e472fa2cffc6cd2051 Mon Sep 17 00:00:00 2001 From: markt Date: Fri, 4 Dec 2009 13:50:36 +0000 Subject: [PATCH] Need to strip /hostname/contextpath before trying to list resources git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@887195 13f79535-47bb-0310-9956-ffa450edef68 --- java/org/apache/naming/resources/DirContextURLConnection.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/java/org/apache/naming/resources/DirContextURLConnection.java b/java/org/apache/naming/resources/DirContextURLConnection.java index cc92b2990..fdea58913 100644 --- a/java/org/apache/naming/resources/DirContextURLConnection.java +++ b/java/org/apache/naming/resources/DirContextURLConnection.java @@ -421,8 +421,13 @@ public class DirContextURLConnection if (collection != null) { try { + String file = getURL().getFile(); + // This will be of the form // enumeration = - context.list(getURL().getFile()); + context.list(file.substring(start)); while (enumeration.hasMoreElements()) { NameClassPair ncp = enumeration.nextElement(); result.addElement(ncp.getName()); -- 2.11.0