summaryrefslogtreecommitdiff
path: root/core/runtime.rs
diff options
context:
space:
mode:
Diffstat (limited to 'core/runtime.rs')
-rw-r--r--core/runtime.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/core/runtime.rs b/core/runtime.rs
index 9a60a65ed..ffd8e49c5 100644
--- a/core/runtime.rs
+++ b/core/runtime.rs
@@ -1572,6 +1572,10 @@ impl JsRuntime {
return exception_to_err_result(tc_scope, exception, false);
}
+ if tc_scope.has_terminated() || tc_scope.is_execution_terminating() {
+ break;
+ }
+
let is_done = is_done.unwrap();
if is_done.is_true() {
break;