diff options
author | Cheng Zhao <zcbenz@gmail.com> | 2021-08-13 11:03:25 +0900 |
---|---|---|
committer | Michaël Zasso <targos@protonmail.com> | 2021-09-18 16:01:29 +0200 |
commit | e4852e3ff5619a7cb626f193da21f8332e887963 (patch) | |
tree | 3f81685580c77ba6b8fb9ae990a340ddb4115904 /src/node_worker.cc | |
parent | 40c6e838dff37d0ccbc95ef28caac13f27a5238f (diff) | |
download | node-new-e4852e3ff5619a7cb626f193da21f8332e887963.tar.gz |
src: add option to disable global search paths
PR-URL: https://github.com/nodejs/node/pull/39754
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Diffstat (limited to 'src/node_worker.cc')
-rw-r--r-- | src/node_worker.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/node_worker.cc b/src/node_worker.cc index dcc76ad88f..16b7be36f2 100644 --- a/src/node_worker.cc +++ b/src/node_worker.cc @@ -572,6 +572,8 @@ void Worker::New(const FunctionCallbackInfo<Value>& args) { worker->environment_flags_ |= EnvironmentFlags::kHideConsoleWindows; if (env->no_native_addons()) worker->environment_flags_ |= EnvironmentFlags::kNoNativeAddons; + if (env->no_global_search_paths()) + worker->environment_flags_ |= EnvironmentFlags::kNoGlobalSearchPaths; } void Worker::StartThread(const FunctionCallbackInfo<Value>& args) { |