Return-Path: Delivered-To: apmail-tomcat-dev-archive@www.apache.org Received: (qmail 6929 invoked from network); 3 May 2010 09:45:32 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 3 May 2010 09:45:32 -0000 Received: (qmail 32631 invoked by uid 500); 3 May 2010 09:45:32 -0000 Delivered-To: apmail-tomcat-dev-archive@tomcat.apache.org Received: (qmail 32466 invoked by uid 500); 3 May 2010 09:45:31 -0000 Mailing-List: contact dev-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Developers List" Delivered-To: mailing list dev@tomcat.apache.org Received: (qmail 32457 invoked by uid 99); 3 May 2010 09:45:31 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 03 May 2010 09:45:31 +0000 X-ASF-Spam-Status: No, hits=-1700.4 required=10.0 tests=ALL_TRUSTED,AWL X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 03 May 2010 09:45:30 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 4B2E723889DA; Mon, 3 May 2010 09:44:40 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r940405 - in /tomcat/trunk: java/org/apache/naming/resources/BaseDirContext.java test/org/apache/catalina/core/TestStandardContextResources.java test/webapp-3.0-fragments/WEB-INF/lib/resources2.jar Date: Mon, 03 May 2010 09:44:40 -0000 To: dev@tomcat.apache.org From: pero@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20100503094440.4B2E723889DA@eris.apache.org> Author: pero Date: Mon May 3 09:44:39 2010 New Revision: 940405 URL: http://svn.apache.org/viewvc?rev=940405&view=rev Log: Search to more jars and fix testcase! Modified: tomcat/trunk/java/org/apache/naming/resources/BaseDirContext.java tomcat/trunk/test/org/apache/catalina/core/TestStandardContextResources.java tomcat/trunk/test/webapp-3.0-fragments/WEB-INF/lib/resources2.jar Modified: tomcat/trunk/java/org/apache/naming/resources/BaseDirContext.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/naming/resources/BaseDirContext.java?rev=940405&r1=940404&r2=940405&view=diff ============================================================================== --- tomcat/trunk/java/org/apache/naming/resources/BaseDirContext.java (original) +++ tomcat/trunk/java/org/apache/naming/resources/BaseDirContext.java Mon May 3 09:44:39 2010 @@ -456,9 +456,13 @@ public abstract class BaseDirContext imp // Check the alternate locations for (DirContext altDirContext : altDirContexts) { - obj = altDirContext.lookup("META-INF/resources/" + name); - if (obj != null) - return obj; + try { + obj = altDirContext.lookup("META-INF/resources/" + name); + if (obj != null) + return obj; + } catch ( NamingException ex) { + // ignore + } } // Really not found Modified: tomcat/trunk/test/org/apache/catalina/core/TestStandardContextResources.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/catalina/core/TestStandardContextResources.java?rev=940405&r1=940404&r2=940405&view=diff ============================================================================== --- tomcat/trunk/test/org/apache/catalina/core/TestStandardContextResources.java (original) +++ tomcat/trunk/test/org/apache/catalina/core/TestStandardContextResources.java Mon May 3 09:44:39 2010 @@ -84,7 +84,7 @@ public class TestStandardContextResource tomcat.start(); assertPageContains("/test/getresource?path=/resourceF.jsp", - "

resourceF.jsp in the web application

"); + "

resourceF.jsp in resources2.jar

"); assertPageContains("/test/getresource?path=/resourceA.jsp", "

resourceA.jsp in the web application

"); assertPageContains("/test/getresource?path=/resourceB.jsp", Modified: tomcat/trunk/test/webapp-3.0-fragments/WEB-INF/lib/resources2.jar URL: http://svn.apache.org/viewvc/tomcat/trunk/test/webapp-3.0-fragments/WEB-INF/lib/resources2.jar?rev=940405&r1=940404&r2=940405&view=diff ============================================================================== Binary files - no diff available. --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org For additional commands, e-mail: dev-help@tomcat.apache.org