Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoyee Cheung <joyeec9h3@gmail.com>2019-09-19 05:36:02 +0300
committerBenjamin Coe <bencoe@google.com>2019-09-24 19:55:00 +0300
commitb2634238d8d50e3801cb716e3f3165be1c50418a (patch)
tree8d8d0828cbdd8feef99fe663b16ae7fc0e627dd5 /src/node_errors.cc
parentc5f5f84a33967862036c7d87f4bbde6a59d3820a (diff)
src: disconnect inspector before exiting out of fatal exception
So that coverage, .etc are properly written in case of a normal fatal exception. PR-URL: https://github.com/nodejs/node/pull/29611 Fixes: https://github.com/nodejs/node/issues/29570 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: David Carlier <devnexen@gmail.com> Reviewed-By: Ben Coe <bencoe@gmail.com>
Diffstat (limited to 'src/node_errors.cc')
-rw-r--r--src/node_errors.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/node_errors.cc b/src/node_errors.cc
index 0214521144c..b33e4936ae7 100644
--- a/src/node_errors.cc
+++ b/src/node_errors.cc
@@ -978,6 +978,9 @@ void TriggerUncaughtException(Isolate* isolate,
// Now we are certain that the exception is fatal.
ReportFatalException(env, error, message, EnhanceFatalException::kEnhance);
+#if HAVE_INSPECTOR
+ profiler::EndStartedProfilers(env);
+#endif
// If the global uncaught exception handler sets process.exitCode,
// exit with that code. Otherwise, exit with 1.