Allow for case when exceptions are created.

This commit is contained in:
Brendan Dahl 2015-08-11 18:05:07 -07:00
Родитель c60ed0549b
Коммит 08ff5275d0
1 изменённых файлов: 1 добавлений и 1 удалений

2
int.ts
Просмотреть файл

@ -2313,7 +2313,7 @@ module J2ME {
// If an exception is thrown from a native there will be a native marker frame at the top of the stack
// which will be cut off when the the fp is set on the thread below. To keep the nativeFrameCount in
// sync the native marker must be popped.
if (thread.fp > fp) {
if (thread.fp > fp && thread.frame.type === FrameType.Native) {
release || assert(i32[thread.fp + FrameLayout.CallerFPOffset] === fp, "Only one extra frame is on the stack. " + (thread.fp - fp));
thread.popMarkerFrame(FrameType.Native);
}