summaryrefslogtreecommitdiff
path: root/doc/api/child_process.md
diff options
context:
space:
mode:
authorSarat Addepalli <sarat.addepalli@paytm.com>2018-08-20 12:41:40 +0530
committerAnna Henningsen <anna@addaleax.net>2018-08-27 23:40:10 +0200
commit68dff4a67b7222770f90fc5d9bdd884f8db4a24b (patch)
tree2815e9c4d88b4c0e7ab5897c38878217cbeb3ba8 /doc/api/child_process.md
parent31b3273eaa02ee12188a4c7a64a0d4adfbe22670 (diff)
downloadandroid-node-v8-68dff4a67b7222770f90fc5d9bdd884f8db4a24b.tar.gz
android-node-v8-68dff4a67b7222770f90fc5d9bdd884f8db4a24b.tar.bz2
android-node-v8-68dff4a67b7222770f90fc5d9bdd884f8db4a24b.zip
child_process: allow typed arrays for input
doc: Update child_process docs, stating typed arrays are allowed. error: Update error message for `ERR_INVALID_SYNC_FORK_INPUT` lib: Use isArrayBufferView instead of isUint8Array test: Update test-child-process-spawnsync-input to test for all typed arrays and data view. PR-URL: https://github.com/nodejs/node/pull/22409 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Diffstat (limited to 'doc/api/child_process.md')
-rw-r--r--doc/api/child_process.md27
1 files changed, 21 insertions, 6 deletions
diff --git a/doc/api/child_process.md b/doc/api/child_process.md
index d6a7942188..e15829ce3f 100644
--- a/doc/api/child_process.md
+++ b/doc/api/child_process.md
@@ -689,6 +689,10 @@ configuration at startup.
added: v0.11.12
changes:
- version: REPLACEME
+ pr-url: https://github.com/nodejs/node/pull/22409
+ description: The `input` option can now be any `TypedArray` or a
+ `DataView`.
+ - version: REPLACEME
pr-url: https://github.com/nodejs/node/pull/21316
description: The `windowsHide` option now defaults to `true`.
- version: v8.8.0
@@ -706,8 +710,9 @@ changes:
* `args` {string[]} List of string arguments.
* `options` {Object}
* `cwd` {string} Current working directory of the child process.
- * `input` {string|Buffer|Uint8Array} The value which will be passed as stdin
- to the spawned process. Supplying this value will override `stdio[0]`.
+ * `input` {string|Buffer|TypedArray|DataView} The value which will be passed
+ as stdin to the spawned process. Supplying this value will override
+ `stdio[0]`.
* `stdio` {string|Array} Child's stdio configuration. `stderr` by default will
be output to the parent process' stderr unless `stdio` is specified.
**Default:** `'pipe'`.
@@ -754,6 +759,10 @@ arbitrary command execution.**
added: v0.11.12
changes:
- version: REPLACEME
+ pr-url: https://github.com/nodejs/node/pull/22409
+ description: The `input` option can now be any `TypedArray` or a
+ `DataView`.
+ - version: REPLACEME
pr-url: https://github.com/nodejs/node/pull/21316
description: The `windowsHide` option now defaults to `true`.
- version: v8.8.0
@@ -767,8 +776,9 @@ changes:
* `command` {string} The command to run.
* `options` {Object}
* `cwd` {string} Current working directory of the child process.
- * `input` {string|Buffer|Uint8Array} The value which will be passed as stdin
- to the spawned process. Supplying this value will override `stdio[0]`.
+ * `input` {string|Buffer|TypedArray|DataView} The value which will be passed
+ as stdin to the spawned process. Supplying this value will override
+ `stdio[0]`.
* `stdio` {string|Array} Child's stdio configuration. `stderr` by default will
be output to the parent process' stderr unless `stdio` is specified.
**Default:** `'pipe'`.
@@ -811,6 +821,10 @@ metacharacters may be used to trigger arbitrary command execution.**
added: v0.11.12
changes:
- version: REPLACEME
+ pr-url: https://github.com/nodejs/node/pull/22409
+ description: The `input` option can now be any `TypedArray` or a
+ `DataView`.
+ - version: REPLACEME
pr-url: https://github.com/nodejs/node/pull/21316
description: The `windowsHide` option now defaults to `true`.
- version: v8.8.0
@@ -831,8 +845,9 @@ changes:
* `args` {string[]} List of string arguments.
* `options` {Object}
* `cwd` {string} Current working directory of the child process.
- * `input` {string|Buffer|Uint8Array} The value which will be passed as stdin
- to the spawned process. Supplying this value will override `stdio[0]`.
+ * `input` {string|Buffer|TypedArray|DataView} The value which will be passed
+ as stdin to the spawned process. Supplying this value will override
+ `stdio[0]`.
* `argv0` {string} Explicitly set the value of `argv[0]` sent to the child
process. This will be set to `command` if not specified.
* `stdio` {string|Array} Child's stdio configuration.