From 0632d59da057e261f53265a8e9e1aec66783d763 Mon Sep 17 00:00:00 2001 From: Shelley Vohr Date: Tue, 6 Oct 2020 11:16:49 -0700 Subject: [PATCH] chore: use noop ShouldAbortOnUncaughtException cb (#25772) --- shell/common/node_bindings.cc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/shell/common/node_bindings.cc b/shell/common/node_bindings.cc index b52f2ef8f431..0b4a77c48178 100644 --- a/shell/common/node_bindings.cc +++ b/shell/common/node_bindings.cc @@ -430,6 +430,12 @@ node::Environment* NodeBindings::CreateEnvironment( // crash message and location to CrashReports. is.fatal_error_callback = V8FatalErrorCallback; + // We don't want to abort either in the renderer or browser processes. + // We already listen for uncaught exceptions and handle them there. + is.should_abort_on_uncaught_exception_callback = [](v8::Isolate*) { + return false; + }; + if (browser_env_ == BrowserEnvironment::BROWSER) { // Node.js requires that microtask checkpoints be explicitly invoked. is.policy = v8::MicrotasksPolicy::kExplicit;