Index: src/debug.cc |
diff --git a/src/debug.cc b/src/debug.cc |
index dec51b9954a5d15cfb04536cd317964335f9c0e8..2ae8630885b804640cd77f5e4363b62cfd5db8a6 100644 |
--- a/src/debug.cc |
+++ b/src/debug.cc |
@@ -1316,11 +1316,9 @@ Handle<Object> Debug::GetPromiseOnStackOnThrow() { |
return thread_local_.promise_on_stack_->promise(); |
} |
handler = handler->next(); |
- // There must be a try-catch handler if a promise is on stack. |
- DCHECK_NE(NULL, handler); |
// Throwing inside a Promise can be intercepted by an inner try-catch, so |
// we stop at the first try-catch handler. |
- } while (!handler->is_catch()); |
+ } while (handler != NULL && !handler->is_catch()); |
return undefined; |
} |