diff options
author | Sam Roberts <vieuxtech@gmail.com> | 2017-04-05 14:06:52 -0700 |
---|---|---|
committer | Sam Roberts <vieuxtech@gmail.com> | 2017-04-13 07:09:39 -0700 |
commit | 8086cb68aefc2f8bfeba412a8706f68cdf3a0b13 (patch) | |
tree | f6bb59176bfaaa373e555d991aea488b8dd4bb51 /src/node_config.cc | |
parent | e505c079e0ff169138d603bf7fa56da937274bbf (diff) | |
download | android-node-v8-8086cb68aefc2f8bfeba412a8706f68cdf3a0b13.tar.gz android-node-v8-8086cb68aefc2f8bfeba412a8706f68cdf3a0b13.tar.bz2 android-node-v8-8086cb68aefc2f8bfeba412a8706f68cdf3a0b13.zip |
src: use option parser for expose_internals
bootstrap_node.js was directly parsing process.execArgv to see if
internals should be exposed, even though the argv was already parsed by
node. This is unusual and unnecessary, change it to set the option value
from the parser onto the config binding.
PR-URL: https://github.com/nodejs/node/pull/12245
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Diffstat (limited to 'src/node_config.cc')
-rw-r--r-- | src/node_config.cc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/node_config.cc b/src/node_config.cc index 5c9c51585b..3c082d6194 100644 --- a/src/node_config.cc +++ b/src/node_config.cc @@ -58,6 +58,9 @@ void InitConfig(Local<Object> target, .ToLocalChecked(); target->DefineOwnProperty(env->context(), name, value).FromJust(); } + + if (config_expose_internals) + READONLY_BOOLEAN_PROPERTY("exposeInternals"); } // InitConfig } // namespace node |