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:
authorDivlo <contact@divlo.fr>2021-09-02 02:59:45 +0300
committerMichael Dawson <mdawson@devrus.com>2021-09-08 20:31:07 +0300
commit59d3d542d69f078cd1d9f50f26b83944c381724e (patch)
tree418aefbd529e5f7261626a3bc1d480d161c35756 /src/node_options.cc
parent33b5107d13f3b5b01861ac7deb4253cfc3d84fc5 (diff)
errors: disp ver on fatal except that causes exit
Display Node.js version at the end of stacktraces on fatal exception that causes exit. Easier for debugging so you don't have to ask "what node version are you on?", it is directly in the error the user copy/paste from when asking for help. Fixes: https://github.com/nodejs/node/issues/29731 PR-URL: https://github.com/nodejs/node/pull/38332 Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: Michael Dawson <midawson@redhat.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Michaƫl Zasso <targos@protonmail.com>
Diffstat (limited to 'src/node_options.cc')
-rw-r--r--src/node_options.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/node_options.cc b/src/node_options.cc
index 40f8cf86902..f66fbc8ed45 100644
--- a/src/node_options.cc
+++ b/src/node_options.cc
@@ -511,6 +511,11 @@ EnvironmentOptionsParser::EnvironmentOptionsParser() {
"show stack traces on process warnings",
&EnvironmentOptions::trace_warnings,
kAllowedInEnvironment);
+ AddOption("--extra-info-on-fatal-exception",
+ "hide extra information on fatal exception that causes exit",
+ &EnvironmentOptions::extra_info_on_fatal_exception,
+ kAllowedInEnvironment,
+ true);
AddOption("--unhandled-rejections",
"define unhandled rejections behavior. Options are 'strict' "
"(always raise an error), 'throw' (raise an error unless "