push method frame for native invocations (so we'll see them in stack traces)

This commit is contained in:
Joel Dice 2007-06-29 20:41:49 -06:00
parent 4020f13fb0
commit b33f0c311d
2 changed files with 5 additions and 1 deletions

View File

@ -7,7 +7,7 @@ public class Throwable {
public Throwable(String message, Throwable cause) {
this.message = message;
this.trace = trace(0);
this.trace = trace(1);
this.cause = cause;
}

View File

@ -3892,8 +3892,12 @@ run(Thread* t)
unsigned base = sp - parameterCount;
if (methodFlags(t, code) & ACC_NATIVE) {
frame = makeFrame(t, code, frame, 0, base, 0, false);
object r = invokeNative(t, code);
frame = frameNext(t, frame);
if (UNLIKELY(exception)) {
goto throw_;
}