Return-Path: Delivered-To: apmail-geronimo-scm-archive@www.apache.org Received: (qmail 62759 invoked from network); 26 Sep 2004 01:56:26 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 26 Sep 2004 01:56:26 -0000 Received: (qmail 38504 invoked by uid 500); 26 Sep 2004 01:56:26 -0000 Delivered-To: apmail-geronimo-scm-archive@geronimo.apache.org Received: (qmail 38337 invoked by uid 500); 26 Sep 2004 01:56:25 -0000 Mailing-List: contact scm-help@geronimo.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Reply-To: dev@geronimo.apache.org Delivered-To: mailing list scm@geronimo.apache.org Received: (qmail 38321 invoked by uid 99); 26 Sep 2004 01:56:25 -0000 X-ASF-Spam-Status: No, hits=-10.0 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [209.237.227.194] (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.28) with SMTP; Sat, 25 Sep 2004 18:56:24 -0700 Received: (qmail 62731 invoked by uid 65534); 26 Sep 2004 01:56:23 -0000 Date: 26 Sep 2004 01:56:23 -0000 Message-ID: <20040926015623.62728.qmail@minotaur.apache.org> From: jboynes@apache.org To: scm@geronimo.apache.org Subject: svn commit: rev 47233 - geronimo/trunk/modules/common/src/java/org/apache/geronimo/common/propertyeditor X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Author: jboynes Date: Sat Sep 25 18:56:23 2004 New Revision: 47233 Modified: geronimo/trunk/modules/common/src/java/org/apache/geronimo/common/propertyeditor/PropertyEditors.java Log: When loading a property editor we need to search using the supplied classloader Modified: geronimo/trunk/modules/common/src/java/org/apache/geronimo/common/propertyeditor/PropertyEditors.java ============================================================================== --- geronimo/trunk/modules/common/src/java/org/apache/geronimo/common/propertyeditor/PropertyEditors.java (original) +++ geronimo/trunk/modules/common/src/java/org/apache/geronimo/common/propertyeditor/PropertyEditors.java Sat Sep 25 18:56:23 2004 @@ -93,7 +93,16 @@ type = ClassLoading.loadClass(typeName + "$PropertyEditor", classLoader); } - return findEditor(type); + // PropertyEditorManager uses the classloader for object, then system, them context + // We need to force the context loader to that of the user as the Editor may be + // located in a child loader from the type being loader + ClassLoader oldLoader = Thread.currentThread().getContextClassLoader(); + try { + Thread.currentThread().setContextClassLoader(classLoader); + return findEditor(type); + } finally { + Thread.currentThread().setContextClassLoader(oldLoader); + } } /**