@@ -11,13 +11,19 @@ diff --git a/lib/internal/bootstrap/pre_execution.js b/lib/internal/bootstrap/pr
11
11
index 0a7c4a47c11eb4bb360b6a46fccb4692241bd2dc..b4a0f71af5853f427a10449b52509052fbe3facd 100644
12
12
--- a/lib/internal/bootstrap/pre_execution.js
13
13
+++ b/lib/internal/bootstrap/pre_execution.js
14
- @@ -89,8 +89,10 @@ function patchProcessObject(expandArgv1) {
14
+ @@ -92,10 +92,12 @@ function patchProcessObject(expandArgv1) {
15
15
16
16
if (expandArgv1 && process.argv[1] && !process.argv[1].startsWith('-')) {
17
17
// Expand process.argv[1] into a full path.
18
+ - const path = require('path');
19
+ - try {
20
+ - process.argv[1] = path.resolve(process.argv[1]);
21
+ - } catch {}
18
22
+ if (!process.argv[1] || !process.argv[1].startsWith('electron/js2c')) {
19
- const path = require('path');
20
- process.argv[1] = path.resolve(process.argv[1]);
23
+ + const path = require('path');
24
+ + try {
25
+ + process.argv[1] = path.resolve(process.argv[1]);
26
+ + } catch {}
21
27
+ }
22
28
}
23
29
@@ -44,8 +50,8 @@ diff --git a/src/env.h b/src/env.h
44
50
index d22b579b25ce4e6af8ec042e282e94248ea14162..67cefbe35f390ba25b49e422d10bca8b423a49a8 100644
45
51
--- a/src/env.h
46
52
+++ b/src/env.h
47
- @@ -890 ,6 +890 ,15 @@ class Environment : public MemoryRetainer {
48
- uint64_t thread_id = kNoThreadId );
53
+ @@ -885 ,6 +885 ,15 @@ class Environment : public MemoryRetainer {
54
+ ThreadId thread_id);
49
55
~Environment() override;
50
56
51
57
+ void ForceOnlyContextAwareNativeModules() {
@@ -57,7 +63,7 @@ index d22b579b25ce4e6af8ec042e282e94248ea14162..67cefbe35f390ba25b49e422d10bca8b
57
63
+ bool force_context_aware() { return force_context_aware_; }
58
64
+ bool warn_non_context_aware() { return warn_non_context_aware_; }
59
65
+
60
- void InitializeLibuv(bool start_profiler_idle_notifier );
66
+ void InitializeLibuv();
61
67
inline const std::vector<std::string>& exec_argv();
62
68
inline const std::vector<std::string>& argv();
63
69
@@ -1271,6 +1280,9 @@ class Environment : public MemoryRetainer {
0 commit comments