chore: remove Node.js patch on Module.globalPaths (#31275)
* chore: remove Node.js patch on Module.globalPaths * chore: update patches Co-authored-by: PatchUp <73610968+patchup[bot]@users.noreply.github.com>
This commit is contained in:
parent
2a92d8f962
commit
959b657903
11 changed files with 36 additions and 35 deletions
|
@ -1,4 +1,3 @@
|
|||
make_module_globalpaths_a_reference.patch
|
||||
refactor_alter_child_process_fork_to_use_execute_script_with.patch
|
||||
feat_add_uv_loop_watcher_queue_code.patch
|
||||
feat_initialize_asar_support.patch
|
||||
|
|
|
@ -29,7 +29,7 @@ index 9d2799c3c9ac3b216c2289ae4e037dd228844d23..5b31df1207d4417a6f9b784574e37796
|
|||
|
||||
// TODO(joyeecheung): most of these should be deprecated and removed,
|
||||
diff --git a/lib/internal/modules/cjs/loader.js b/lib/internal/modules/cjs/loader.js
|
||||
index 40655b66fd2a50dac01f88d38457de4602022381..95147ec8a95761b0654e8403578c2c67191834ad 100644
|
||||
index 5d75a0e6cb9692a303be6599226f20783e7863b8..eb7f4346035f0897d0f2b140277e48b3c7bb7546 100644
|
||||
--- a/lib/internal/modules/cjs/loader.js
|
||||
+++ b/lib/internal/modules/cjs/loader.js
|
||||
@@ -1075,6 +1075,13 @@ Module.prototype._compile = function(content, filename) {
|
||||
|
|
|
@ -1,22 +0,0 @@
|
|||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Cheng Zhao <zcbenz@gmail.com>
|
||||
Date: Sun, 14 Apr 2013 15:54:46 +0800
|
||||
Subject: Make Module.globalPaths a reference.
|
||||
|
||||
We need to hack the search paths of the require function so we can
|
||||
load libraries from embedded applications without modifications of
|
||||
node's module code.
|
||||
|
||||
diff --git a/lib/internal/modules/cjs/loader.js b/lib/internal/modules/cjs/loader.js
|
||||
index 3f1dac356b81f437503422a8fb69df792db9c523..8258a46076d1d4905298016cb52247e2cf8432c5 100644
|
||||
--- a/lib/internal/modules/cjs/loader.js
|
||||
+++ b/lib/internal/modules/cjs/loader.js
|
||||
@@ -1251,7 +1251,7 @@ Module._initPaths = function() {
|
||||
modulePaths = paths;
|
||||
|
||||
// Clone as a shallow copy, for introspection.
|
||||
- Module.globalPaths = ArrayPrototypeSlice(modulePaths);
|
||||
+ Module.globalPaths = modulePaths;
|
||||
};
|
||||
|
||||
Module._preloadModules = function(requests) {
|
|
@ -6,7 +6,7 @@ Subject: Pass all globals through "require"
|
|||
(cherry picked from commit 7d015419cb7a0ecfe6728431a4ed2056cd411d62)
|
||||
|
||||
diff --git a/lib/internal/modules/cjs/loader.js b/lib/internal/modules/cjs/loader.js
|
||||
index 8258a46076d1d4905298016cb52247e2cf8432c5..71059956705d1299a19cc9c940a998d9e9717a21 100644
|
||||
index 3f1dac356b81f437503422a8fb69df792db9c523..dfaea25243826878afc0af96a77d0aef153fa76b 100644
|
||||
--- a/lib/internal/modules/cjs/loader.js
|
||||
+++ b/lib/internal/modules/cjs/loader.js
|
||||
@@ -127,6 +127,13 @@ const {
|
||||
|
|
|
@ -22,7 +22,7 @@ index 58f7396990dddb7dd4cf3d23fcdcc1d48f52623e..ef06d0563fa7452348754418867a56c9
|
|||
const nativeModule = internalBinding('native_module');
|
||||
|
||||
diff --git a/lib/internal/modules/cjs/loader.js b/lib/internal/modules/cjs/loader.js
|
||||
index 71059956705d1299a19cc9c940a998d9e9717a21..40655b66fd2a50dac01f88d38457de4602022381 100644
|
||||
index dfaea25243826878afc0af96a77d0aef153fa76b..5d75a0e6cb9692a303be6599226f20783e7863b8 100644
|
||||
--- a/lib/internal/modules/cjs/loader.js
|
||||
+++ b/lib/internal/modules/cjs/loader.js
|
||||
@@ -86,7 +86,7 @@ const fs = require('fs');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue