child_process: make process_wrap binding internal
PR-URL: https://github.com/nodejs/node/pull/22479 Refs: https://github.com/nodejs/node/issues/22160 Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
This commit is contained in:
parent
68dff4a67b
commit
56cf058878
@ -350,6 +350,7 @@
|
||||
new SafeSet([
|
||||
'uv',
|
||||
'http_parser',
|
||||
'process_wrap',
|
||||
'v8',
|
||||
'stream_wrap',
|
||||
'signal_wrap',
|
||||
|
@ -23,7 +23,7 @@ const assert = require('assert');
|
||||
|
||||
const { internalBinding } = require('internal/bootstrap/loaders');
|
||||
|
||||
const { Process } = process.binding('process_wrap');
|
||||
const { Process } = internalBinding('process_wrap');
|
||||
const { WriteWrap } = internalBinding('stream_wrap');
|
||||
const { Pipe, constants: PipeConstants } = process.binding('pipe_wrap');
|
||||
const { TTY } = process.binding('tty_wrap');
|
||||
|
@ -315,4 +315,4 @@ class ProcessWrap : public HandleWrap {
|
||||
} // anonymous namespace
|
||||
} // namespace node
|
||||
|
||||
NODE_BUILTIN_MODULE_CONTEXT_AWARE(process_wrap, node::ProcessWrap::Initialize)
|
||||
NODE_MODULE_CONTEXT_AWARE_INTERNAL(process_wrap, node::ProcessWrap::Initialize)
|
||||
|
@ -1,3 +1,4 @@
|
||||
// Flags: --expose-internals
|
||||
// Copyright Joyent, Inc. and other Node contributors.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||
@ -22,7 +23,8 @@
|
||||
'use strict';
|
||||
require('../common');
|
||||
const assert = require('assert');
|
||||
const Process = process.binding('process_wrap').Process;
|
||||
const { internalBinding } = require('internal/test/binding');
|
||||
const Process = internalBinding('process_wrap').Process;
|
||||
const { Pipe, constants: PipeConstants } = process.binding('pipe_wrap');
|
||||
const pipe = new Pipe(PipeConstants.SOCKET);
|
||||
const p = new Process();
|
||||
|
@ -182,7 +182,7 @@ if (common.hasCrypto) { // eslint-disable-line node-core/crypto-check
|
||||
}
|
||||
|
||||
{
|
||||
const Process = process.binding('process_wrap').Process;
|
||||
const Process = internalBinding('process_wrap').Process;
|
||||
testInitialized(new Process(), 'Process');
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user