[kaffe] NPE while printing a stack trace

Daniel Bonniot Daniel.Bonniot at inria.fr
Thu Jun 9 09:26:35 PDT 2005


Helmer, thanks a lot for your fix!

With the same setup, here is another bug (I have been seeing it for a lot 
time, but could not reproduce it reliably until now):

$ cat trace.t
/// PASS bug
   int[][] l = [[0,1],[1,2]];
   int[] bar = l.map(<T> (T[] x) => x[1]);
You have new mail.
$ /usr/local/src/kaffe/install/bin/kaffe -cp /usr/share/java/nice.jar \
nice.tools.testsuite.TestNice -runtime /usr/share/java/nice.jar trace.t
run test engine
   testsuite: trace.t
java.lang.NullPointerException
    at java.lang.Object.getClass (Object.java:331)
    at java.lang.VMSystem.arraycopy (VMSystem.java:92)
    at java.lang.System.arraycopy (System.java:234)
    at java.lang.String.getChars (String.java:398)
    at java.lang.StringBuffer.append (StringBuffer.java:314)
    at java.lang.StackTraceElement.toString (StackTraceElement.java:193)
    at java.lang.Throwable.stackTraceStringBuffer (Throwable.java:477)
    at java.lang.Throwable.stackTraceString (Throwable.java:418)
    at java.lang.Throwable.printStackTrace (Throwable.java:398)
    at nice.lang.fun.printStackTraceWithSourceInfo (source file unknown:735)
    at nice.lang.dispatch.printStackTraceWithSourceInfo (source file 
unknown:line unknown, pc 0x93820a2)
    at nice.lang.fun.printStackTraceWithSourceInfo (source file unknown:line 
unknown, pc 0x9382110)
    at nice.lang.dispatch.printStackTraceWithSourceInfo (source file 
unknown:line unknown, pc 0x93822cb)
    at nice.tools.compiler.fun.compile (source file unknown:61)
    at nice.tools.testsuite.TestCase.compilePackage (TestCase.java:337)
    at nice.tools.testsuite.TestCase.compilePackages (TestCase.java:295)
    at nice.tools.testsuite.PassTestCase.performTest (PassTestCase.java:45)
    at nice.tools.testsuite.TestSuite.performTests (TestSuite.java:216)
    at nice.tools.testsuite.TestSuite.<init> (TestSuite.java:85)
    at nice.tools.testsuite.TestNice.performTests (TestNice.java:414)
    at nice.tools.testsuite.TestNice.main (TestNice.java:208)


The good news is that after working around this bug (and lots of memory), 
kaffe can run Nice's entire testsuite with no bug (besides one that I already 
fixed in classpath). Awesome!

So after this bug is fixed, things should start to look quite good from my 
point of view.

Cheers,

Daniel




More information about the kaffe mailing list