Return-Path: Delivered-To: apmail-harmony-commits-archive@www.apache.org Received: (qmail 27105 invoked from network); 5 Feb 2007 12:55:27 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 5 Feb 2007 12:55:27 -0000 Received: (qmail 86873 invoked by uid 500); 5 Feb 2007 12:55:33 -0000 Delivered-To: apmail-harmony-commits-archive@harmony.apache.org Received: (qmail 86841 invoked by uid 500); 5 Feb 2007 12:55:33 -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 86832 invoked by uid 99); 5 Feb 2007 12:55:33 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 05 Feb 2007 04:55:33 -0800 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, 05 Feb 2007 04:55:26 -0800 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id ED6B87142E1 for ; Mon, 5 Feb 2007 04:55:05 -0800 (PST) Message-ID: <29646184.1170680105969.JavaMail.jira@brutus> Date: Mon, 5 Feb 2007 04:55:05 -0800 (PST) From: "Tim Ellison (JIRA)" To: commits@harmony.apache.org Subject: [jira] Assigned: (HARMONY-3094) [classlib][luni] java.net.URL.setupStreamHandler() works incorrectly if set System property "java.protocol.handler.pkgs" In-Reply-To: <386735.1170225725744.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-3094?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Tim Ellison reassigned HARMONY-3094: ------------------------------------ Assignee: Tim Ellison > [classlib][luni] java.net.URL.setupStreamHandler() works incorrectly if set System property "java.protocol.handler.pkgs" > ------------------------------------------------------------------------------------------------------------------------ > > Key: HARMONY-3094 > URL: https://issues.apache.org/jira/browse/HARMONY-3094 > Project: Harmony > Issue Type: Bug > Components: Classlib > Reporter: Igor V. Stolyarov > Assigned To: Tim Ellison > Attachments: H-3094_test.patch, Harmony-3094.patch > > > java.net.URL.setupStreamHandler() works incorrectly if set System property "java.protocol.handler.pkgs" > Test-------------------------------------------------------------------------- > public class Hello{ > public static void main(String argv[]){ > System.out.println("Hello world!"); > } > } > import java.net.*; > import java.io.*; > public class Test{ > public static void main(String argv[]){ > try { > URL jarUrl = new URL("jar", "", -1, "file:hello.jar!/"); > URLClassLoader ucl = new URLClassLoader(new URL[]{jarUrl}); > URL url = ucl.getResource("Hello.class"); > System.out.println("url = " + url); > } catch (Exception e) { > e.printStackTrace(); > } > } > } > Steps to reproduce: > 1. Compile Hello.java > 2. Create hello.jar and put Hello.class into hello.jar > 3. Compile Test.java > 4. run Test: java -Djava.protocol.handler.pkgs="org.jboss.protocol" Test > Output: > JRockit jdk: > C:\test>java -showversion -Djava.protocol.handler.pkgs="org.www.protocol" Test > java version "1.5.0" > Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-b64) > BEA WebLogic JRockit(R) (build dra-38972-20041208-2001-win-ia32, R25.0.0-75, GC: > System optimized over throughput (initial strategy singleparpar)) > url = jar:file:hello.jar!/Hello.class > ------------------------- > Harmony: > C:\test>java -showversion -Djava.protocol.handler.pkgs="org.www.protocol" Test > Apache Harmony Launcher : (c) Copyright 1991, 2006 The Apache Software Foundatio > n or its licensors, as applicable. > java version "1.5.0" > pre-alpha : not complete or compatible > svn = r500207, (Jan 26 2007), Windows/ia32/msvc 1310, debug build > http://incubator.apache.org/harmony > java.lang.NullPointerException > at java.util.ResourceBundle.getBundle(ResourceBundle.java:123) > at org.apache.harmony.luni.util.MsgHelp$1.run(MsgHelp.java:115) > at java.security.AccessController.doPrivilegedImpl(Unknown Source) > at java.security.AccessController.doPrivileged(Unknown Source) > at org.apache.harmony.luni.util.MsgHelp.setLocale(MsgHelp.java:112) > at org.apache.harmony.luni.util.Msg.(Msg.java:50) > at java.net.URL.(URL.java:313) > at java.net.URL.(URL.java) > at java.net.URI.toURL(URI.java:1529) > at java.lang.ClassLoader$SystemClassLoader.(Unknown Source) > at java.lang.ClassLoader.initSystemClassLoader(Unknown Source) > at java.lang.ClassLoader.getSystemClassLoader(Unknown Source) > at java.lang.Thread.(Unknown Source) > Uncaught exception in main: > java.lang.NoClassDefFoundError: Test > Caused by: java.lang.ClassNotFoundException: Test > at java.net.URLClassLoader.findClass(URLClassLoader.java:623) > at java.lang.ClassLoader.loadClass(Unknown Source) > at java.lang.ClassLoader$SystemClassLoader.loadClass(Unknown Source) > at java.lang.ClassLoader.loadClass(Unknown Source) > FAILED to invoke JVM. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.