diff options
author | cjihrig <cjihrig@gmail.com> | 2019-02-18 14:01:12 -0500 |
---|---|---|
committer | cjihrig <cjihrig@gmail.com> | 2019-02-20 15:15:57 -0500 |
commit | 823c988b482e609978869820758b7182f32e9de5 (patch) | |
tree | 40f0445410b16afeec0e2e273e4890bb82e5e90e /src/node_report_module.cc | |
parent | 11a8a940d7bf03dc108082bdd456668210b949c1 (diff) | |
download | node-new-823c988b482e609978869820758b7182f32e9de5.tar.gz |
report: remove verbose setting
This commit removes the --diagnostic-report-verbose CLI option
and all associated logic. The flag is currently only used in one
place, and only reflects the settings at startup. Additionally,
Node tends to use the NODE_DEBUG mechanism for adding verbose
output.
PR-URL: https://github.com/nodejs/node/pull/26195
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Diffstat (limited to 'src/node_report_module.cc')
-rw-r--r-- | src/node_report_module.cc | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/src/node_report_module.cc b/src/node_report_module.cc index d13eb61c83..f56da94bac 100644 --- a/src/node_report_module.cc +++ b/src/node_report_module.cc @@ -167,17 +167,6 @@ void SyncConfig(const FunctionCallbackInfo<Value>& info) { Utf8Value pathstr(env->isolate(), path); - // Report verbosity - Local<String> verbosekey = FIXED_ONE_BYTE_STRING(env->isolate(), "verbose"); - Local<Value> verbose_unchecked; - if (!obj->Get(context, verbosekey).ToLocal(&verbose_unchecked)) return; - Local<Boolean> verbose; - if (verbose_unchecked->IsUndefined() || verbose_unchecked->IsNull()) - verbose_unchecked = Boolean::New(env->isolate(), "verbose"); - verbose = verbose_unchecked.As<Boolean>(); - - bool verb = verbose->BooleanValue(env->isolate()); - if (sync) { static const std::string e = "exception"; static const std::string s = "signal"; @@ -202,7 +191,6 @@ void SyncConfig(const FunctionCallbackInfo<Value>& info) { options->report_filename = *filestr; CHECK_NOT_NULL(*pathstr); options->report_directory = *pathstr; - options->report_verbose = verb; } else { int i = 0; if (options->report_uncaught_exception && @@ -242,12 +230,6 @@ void SyncConfig(const FunctionCallbackInfo<Value>& info) { .ToLocal(&path_value)) return; if (!obj->Set(context, pathkey, path_value).FromJust()) return; - - if (!obj->Set(context, - verbosekey, - Boolean::New(env->isolate(), options->report_verbose)) - .FromJust()) - return; } } @@ -261,22 +243,6 @@ static void Initialize(Local<Object> exports, env->SetMethod(exports, "onUnCaughtException", OnUncaughtException); env->SetMethod(exports, "onUserSignal", OnUserSignal); env->SetMethod(exports, "syncConfig", SyncConfig); - - // TODO(gireeshpunathil) if we are retaining this flag, - // insert more verbose information at vital control flow - // points. Right now, it is only this one. - if (options->report_verbose) { - std::cerr << "report: initialization complete, event flags:" << std::endl; - std::cerr << "report_uncaught_exception: " - << options->report_uncaught_exception << std::endl; - std::cerr << "report_on_signal: " << options->report_on_signal << std::endl; - std::cerr << "report_on_fatalerror: " << options->report_on_fatalerror - << std::endl; - std::cerr << "report_signal: " << options->report_signal << std::endl; - std::cerr << "report_filename: " << options->report_filename << std::endl; - std::cerr << "report_directory: " << options->report_directory << std::endl; - std::cerr << "report_verbose: " << options->report_verbose << std::endl; - } } } // namespace report |