stack overflows by java.lang.reflect.Array.newInstance(Class,int)

Andrew Haley aph@redhat.com
Thu Oct 28 16:36:00 GMT 2004


Bojan Antonovic writes:
 > I have a problem with Sun's/Apple's java AND gij. In my code I'm using 
 > java.lang.reflect.Array.newInstance(Class,int). But from a point on, I 
 > can't continue because Array.newInstance and
 > 
 > Bla[] x=new Bla[size];
 > 
 > are producing a StackOverflowError on java and a bus error with gij. The 
 > point is that I'm NOT in a recursion, because I can see the output on 
 > the console. gdb shows for gij:
 > 
 > Program received signal EXC_BAD_ACCESS, Could not access memory.
 > 0x02c243cc in _Jv_InterpMethod::run(void*, ffi_raw*) (this=0x60640, 
 > retp=0x0, args=0xbf800140) at ../../../gcc-3.4.2/libjava/interpret.cc:786
 > 786 {
That probably is a stack overflow.
 > Does somebody know how the stack size can be increased, or if this is a 
 > bug? Array.newInstance is a native method. Giving more memory by -Xmx 
 > and -Xss doesn't help.
Show us your code ...
Andrew.


More information about the Java mailing list

AltStyle によって変換されたページ (->オリジナル) /