segfault when calling Constructor.getParameterAnnotations
Brought to you by:
rlougher
Running jamvm 1.5.4.
I get the same error on my ubuntu 10.04 box and on the OpenWrt mips build I develop for.
The following code reproduces the problem:
--------
Class<?> clazz = String.class;
Constructor<?>[] ctors = clazz.getConstructors();
System.out.println("Pre Constructor.getParameterAnnotations()");
for(Constructor<?> ctor : ctors) {
System.out.println("Parm annotations: [" + ctor.getParameterAnnotations().length + "]");
}
System.out.println("Post Constructor.getParameterAnnotations()");
--------
The code only prints the first stdout and then segfaults
Hi,
This has been fixed and will be in the next release. You can get the latest version from CVS, or you can patch 1.5.4. The change is minor:
http://cvs.berlios.de/cgi-bin/viewvc.cgi/jamvm/jamvm/src/natives.c?r1=1.47&r2=1.48
Rob.