Restore previous unwind_state.

This commit is contained in:
losfair
2019-08-22 17:22:33 -07:00
parent d7c5bb904e
commit f503764780

View File

@ -44,6 +44,8 @@ void catch_unwind(std::function<void()> &&f) {
unwind_state = &current;
unwinding_setjmp(current.stack, unwind_payload, (void *)&current);
unwind_state = current.prev;
if (current.exception) {
throw *current.exception;
}