summaryrefslogtreecommitdiff
path: root/lib/internal/bootstrap/loaders.js
diff options
context:
space:
mode:
authorAnna Henningsen <anna@addaleax.net>2018-10-15 01:41:32 +0200
committerAnna Henningsen <anna@addaleax.net>2018-10-21 03:17:12 +0200
commit87b808f7611b5ed17164f939760f562d5af9fdb4 (patch)
tree2462cb1b292756df8f844891eeddd75edd81a084 /lib/internal/bootstrap/loaders.js
parent20282b1cb0389553421c4c5b14de198c5dfff50b (diff)
downloadandroid-node-v8-87b808f7611b5ed17164f939760f562d5af9fdb4.tar.gz
android-node-v8-87b808f7611b5ed17164f939760f562d5af9fdb4.tar.bz2
android-node-v8-87b808f7611b5ed17164f939760f562d5af9fdb4.zip
src,lib: move `natives` and `constants` to `internalBinding()`
Refs: https://github.com/nodejs/node/issues/22160 PR-URL: https://github.com/nodejs/node/pull/23663 Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Weijia Wang <starkwang@126.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com> Reviewed-By: Denys Otrishko <shishugi@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com>
Diffstat (limited to 'lib/internal/bootstrap/loaders.js')
-rw-r--r--lib/internal/bootstrap/loaders.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/internal/bootstrap/loaders.js b/lib/internal/bootstrap/loaders.js
index b3072a0294..dff6ce661a 100644
--- a/lib/internal/bootstrap/loaders.js
+++ b/lib/internal/bootstrap/loaders.js
@@ -123,7 +123,7 @@
this.script = null; // The ContextifyScript of the module
}
- NativeModule._source = getBinding('natives');
+ NativeModule._source = getInternalBinding('natives');
NativeModule._cache = {};
const config = getBinding('config');
@@ -256,12 +256,12 @@
// 1. `internalBinding('code_cache_hash')` must be in sync with
// `internalBinding('code_cache')` (same C++ file)
// 2. `internalBinding('natives_hash')` must be in sync with
- // `process.binding('natives')` (same C++ file)
+ // `internalBinding('natives')` (same C++ file)
// 3. If `internalBinding('natives_hash')` is in sync with
// `internalBinding('natives_hash')`, then the (unwrapped)
// code used to generate `internalBinding('code_cache')`
// should be in sync with the (unwrapped) code in
- // `process.binding('natives')`
+ // `internalBinding('natives')`
// There will be, however, false positives if the wrapper used
// to generate the cache is different from the one used at run time,
// and the length of the wrapper somehow stays the same.