Return-Path: Delivered-To: apmail-felix-commits-archive@www.apache.org Received: (qmail 7244 invoked from network); 24 Sep 2008 14:14:08 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 24 Sep 2008 14:14:08 -0000 Received: (qmail 83771 invoked by uid 500); 24 Sep 2008 14:14:02 -0000 Delivered-To: apmail-felix-commits-archive@felix.apache.org Received: (qmail 83747 invoked by uid 500); 24 Sep 2008 14:14:02 -0000 Mailing-List: contact commits-help@felix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@felix.apache.org Delivered-To: mailing list commits@felix.apache.org Received: (qmail 83734 invoked by uid 99); 24 Sep 2008 14:14:01 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 24 Sep 2008 07:14:01 -0700 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED 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; Wed, 24 Sep 2008 14:13:09 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 677BC2388970; Wed, 24 Sep 2008 07:13:13 -0700 (PDT) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r698580 - /felix/trunk/framework/src/main/java/org/apache/felix/framework/searchpolicy/R4SearchPolicyCore.java Date: Wed, 24 Sep 2008 14:13:13 -0000 To: commits@felix.apache.org From: pauls@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20080924141313.677BC2388970@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: pauls Date: Wed Sep 24 07:13:12 2008 New Revision: 698580 URL: http://svn.apache.org/viewvc?rev=698580&view=rev Log: Do not bootdelegate in case Bundle.loadClass() has been used. (FELIX-712) Modified: felix/trunk/framework/src/main/java/org/apache/felix/framework/searchpolicy/R4SearchPolicyCore.java Modified: felix/trunk/framework/src/main/java/org/apache/felix/framework/searchpolicy/R4SearchPolicyCore.java URL: http://svn.apache.org/viewvc/felix/trunk/framework/src/main/java/org/apache/felix/framework/searchpolicy/R4SearchPolicyCore.java?rev=698580&r1=698579&r2=698580&view=diff ============================================================================== --- felix/trunk/framework/src/main/java/org/apache/felix/framework/searchpolicy/R4SearchPolicyCore.java (original) +++ felix/trunk/framework/src/main/java/org/apache/felix/framework/searchpolicy/R4SearchPolicyCore.java Wed Sep 24 07:13:12 2008 @@ -54,6 +54,7 @@ import org.osgi.framework.InvalidSyntaxException; import org.osgi.framework.PackagePermission; import org.osgi.framework.Version; +import org.osgi.framework.Bundle; public class R4SearchPolicyCore implements ModuleListener { @@ -595,7 +596,13 @@ break; } } - if (delegate) + // If delegate is true then there are no bundles + // providing exports for this package and the instigating + // class was not from a bundle. Therefore, + // delegate to the parent class loader in case + // that this is not due to outside code calling a method + // on the bundle interface (e.g., Bundle.loadClass()). + if (delegate && !Bundle.class.isInstance(classes[i - 1])) { try {