GeezerVison is showing github.com — Revert "os: move process.binding('os') to internalBinding" · nodejs/node@f64e5ec
File tree
Expand file treeCollapse file tree
Open diff view settings
Expand file treeCollapse file tree
Open diff view settings
Collapse file
Copy file name to clipboardExpand all lines: lib/internal/bootstrap/loaders.js -1Lines changed: 0 additions & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
|
87 | 87 | 'icu', |
88 | 88 | 'js_stream', |
89 | 89 | 'natives', |
90 | | - 'os', |
91 | 90 | 'pipe_wrap', |
92 | 91 | 'process_wrap', |
93 | 92 | 'signal_wrap', |
|
Collapse file
Copy file name to clipboardExpand all lines: lib/os.js +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -44,7 +44,7 @@ const { |
44 | 44 | getUptime, |
45 | 45 | isBigEndian, |
46 | 46 | setPriority: _setPriority |
47 | | -} = internalBinding('os'); |
| 47 | +} = process.binding('os'); |
48 | 48 |
|
49 | 49 | function getCheckedFunction(fn) { |
50 | 50 | return function checkError(...args) { |
|
Collapse file
Copy file name to clipboardExpand all lines: src/node_os.cc +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -467,4 +467,4 @@ void Initialize(Local<Object> target, |
467 | 467 | } // namespace os |
468 | 468 | } // namespace node |
469 | 469 |
|
470 | | -NODE_MODULE_CONTEXT_AWARE_INTERNAL(os, node::os::Initialize) |
| 470 | +NODE_BUILTIN_MODULE_CONTEXT_AWARE(os, node::os::Initialize) |
Collapse file
Copy file name to clipboardExpand all lines: test/parallel/test-os-checked-function.js +1-5Lines changed: 1 addition & 5 deletions | Original file line number | Diff line number | Diff line change |
|---|
|
1 | 1 | 'use strict'; |
2 | | -// Flags: --expose_internals |
3 | | - |
4 | | -const { internalBinding } = require('internal/test/binding'); |
5 | | - |
6 | 2 | // Monkey patch the os binding before requiring any other modules, including |
7 | 3 | // common, which requires the os module. |
8 | | -internalBinding('os').getHomeDirectory = function(ctx) { |
| 4 | +process.binding('os').getHomeDirectory = function(ctx) { |
9 | 5 | ctx.syscall = 'foo'; |
10 | 6 | ctx.code = 'bar'; |
11 | 7 | ctx.message = 'baz'; |
|
Collapse file
Copy file name to clipboardExpand all lines: test/parallel/test-process-binding-internalbinding-whitelist.js -1Lines changed: 0 additions & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -16,4 +16,3 @@ assert(process.binding('url')); |
16 | 16 | assert(process.binding('spawn_sync')); |
17 | 17 | assert(process.binding('js_stream')); |
18 | 18 | assert(process.binding('buffer')); |
19 | | -assert(process.binding('os')); |