harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vincent Siveton (JIRA)" <j...@apache.org>
Subject [jira] Created: (HARMONY-6057) Class.forName() throws java.lang.IndexOutOfBoundsException
Date Mon, 22 Dec 2008 12:48:44 GMT
Class.forName() throws java.lang.IndexOutOfBoundsException
----------------------------------------------------------

                 Key: HARMONY-6057
                 URL: https://issues.apache.org/jira/browse/HARMONY-6057
             Project: Harmony
          Issue Type: Bug
          Components: JDK
    Affects Versions: 5.0M8
            Reporter: Vincent Siveton


Using latest harmony (r713673), I notified that calling Class.forName( "foo.bar.com" ); throws
IndexOutOfBoundsException.

Here is the stacktrace:
{noformat}
http://harmony.apache.org
Uncaught exception in main:
java.lang.IndexOutOfBoundsException
	at java.nio.ByteBuffer.wrap(ByteBuffer.java:110)
	at java.util.jar.InitManifest.decode(InitManifest.java:210)
	at java.util.jar.InitManifest.readValue(InitManifest.java:201)
	at java.util.jar.InitManifest.readHeader(InitManifest.java:117)
	at java.util.jar.InitManifest.<init>(InitManifest.java:56)
	at java.util.jar.Manifest.read(Manifest.java:223)
	at java.util.jar.Manifest.<init>(Manifest.java:116)
	at java.util.jar.JarFile.getManifest(JarFile.java:268)
	at java.net.URLClassLoader.createURLJarHandler(URLClassLoader.java:1044)
	at java.net.URLClassLoader.makeNewHandler(URLClassLoader.java:997)
	at java.net.URLClassLoader.getHandler(URLClassLoader.java:980)
	at java.net.URLClassLoader.findClassImpl(URLClassLoader.java:1189)
	at java.net.URLClassLoader$4.run(URLClassLoader.java:888)
	at java.net.URLClassLoader$4.run(URLClassLoader.java:1)
	at java.security.AccessController.doPrivilegedImpl(AccessController.java:171)
	at java.security.AccessController.doPrivileged(AccessController.java:64)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:885)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:489)
	at java.lang.ClassLoader$SystemClassLoader.loadClass(ClassLoader.java:871)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:268)
	at java.lang.Class.forName(Class.java:130)
	at java.lang.Class.forName(Class.java:90)
	at test.Test.main(Test.java:32)
{noformat}

Here is the dummy code:
{noformat}
public class Test
{
    public static void main( String[] args )
        throws Exception
    {
        System.out.println( System.getProperty( "java.vendor.url" ) );

        Class.forName( "foo.bar.com" );
    }
}
{noformat}

This project uses only one dependency: icu4j [1]. I tried with some other icu4j distributions
[2] with success.

[1] http://repo2.maven.org/eclipse/com/ibm/icu/com.ibm.icu/3.4.5/com.ibm.icu-3.4.5.jar
[2] http://repo2.maven.org/maven2/com/ibm/icu/icu4j/

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message