Return-Path: Delivered-To: apmail-harmony-commits-archive@www.apache.org Received: (qmail 98035 invoked from network); 19 Mar 2007 18:46:53 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 19 Mar 2007 18:46:53 -0000 Received: (qmail 90191 invoked by uid 500); 19 Mar 2007 18:47:01 -0000 Delivered-To: apmail-harmony-commits-archive@harmony.apache.org Received: (qmail 90170 invoked by uid 500); 19 Mar 2007 18:47:01 -0000 Mailing-List: contact commits-help@harmony.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@harmony.apache.org Delivered-To: mailing list commits@harmony.apache.org Received: (qmail 90148 invoked by uid 99); 19 Mar 2007 18:47:01 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 19 Mar 2007 11:47:01 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 19 Mar 2007 11:46:52 -0700 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 8B631714076 for ; Mon, 19 Mar 2007 11:46:32 -0700 (PDT) Message-ID: <19740628.1174329992567.JavaMail.jira@brutus> Date: Mon, 19 Mar 2007 11:46:32 -0700 (PDT) From: "Vasily Zakharov (JIRA)" To: commits@harmony.apache.org Subject: [jira] Closed: (HARMONY-3398) [classlib][swing] UIDefaults.getUIClass() uses wrong classloader In-Reply-To: <33328269.1173924909496.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HARMONY-3398?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Vasily Zakharov closed HARMONY-3398. ------------------------------------ Thanks, Alexey, the patch applied fine. Verified, closing. > [classlib][swing] UIDefaults.getUIClass() uses wrong classloader > ---------------------------------------------------------------- > > Key: HARMONY-3398 > URL: https://issues.apache.org/jira/browse/HARMONY-3398 > Project: Harmony > Issue Type: Bug > Components: Classlib > Reporter: Vasily Zakharov > Assigned To: Alexey Petrenko > Attachments: Harmony-3398-fix.patch, Harmony-3398-test.patch, Harmony-3398-test.patch > > > For now getUIClass(String) uses ClassLoader.getSystemClassLoader() while it should pass null to getUIClass(String, ClassLoader) instead, as the spec states: > Returns: the Class object returned by getUIClass(uiClassID, null) > Also, getUIClass(String, ClassLoader), if passed null classloader, now passes that null to class.forName(), which makes third-party classes loaded by non-system classloader unavailable for this method. It looks like using Thread.currentThread().getContextClassLoader() instead is a proper solution. Reasons for using "false" in Class.forName() are also unclear. > The test in the attached test patch passes on RI but fails on Harmony, and works fine after the attached fix patch is applied. > This issue was discovered while investigating issue HARMONY-3385. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.