don't try printing a potentially corrupt stack after OOS (issue #371)

This commit is contained in:
Alex Shinn 2016-07-10 08:30:30 +09:00
parent 50d7cedb3f
commit 57c6d7c1ec

1
main.c
View file

@ -154,6 +154,7 @@ static void repl (sexp ctx, sexp env) {
#endif
if (res && sexp_exceptionp(res)) {
sexp_print_exception(ctx, res, err);
if (res != sexp_global(ctx, SEXP_G_OOS_ERROR))
sexp_stack_trace(ctx, err);
} else if (res != SEXP_VOID) {
sexp_write(ctx, res, out);