Skip to content

Commit

Permalink
src: rename --security-reverts to ...-revert
Browse files Browse the repository at this point in the history
It was called --security-revert prior to 12.x, but changed in
#22490.

See:
nodejs/nodejs.org#2412 (comment)

PR-URL: #29153
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Beth Griggs <[email protected]>
Reviewed-By: Rich Trott <[email protected]>
Reviewed-By: Trivikram Kamat <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
sam-github authored and targos committed Aug 19, 2019
1 parent 7f11c72 commit a6b9299
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
7 changes: 6 additions & 1 deletion src/node_options.cc
Original file line number Diff line number Diff line change
Expand Up @@ -645,7 +645,12 @@ PerProcessOptionsParser::PerProcessOptionsParser(
&PerProcessOptions::debug_arraybuffer_allocations,
kAllowedInEnvironment);

AddOption("--security-reverts", "", &PerProcessOptions::security_reverts);

// 12.x renamed this inadvertently, so alias it for consistency within the
// release line, while using the original name for consistency with older
// release lines.
AddOption("--security-revert", "", &PerProcessOptions::security_reverts);
AddAlias("--security-reverts", "--security-revert");
AddOption("--completion-bash",
"print source-able bash completion script",
&PerProcessOptions::print_bash_completion);
Expand Down
2 changes: 1 addition & 1 deletion test/parallel/test-security-revert-unknown.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const { spawnSync } = require('child_process');
const os = require('os');

const { signal, status, output } =
spawnSync(process.execPath, ['--security-reverts=not-a-cve']);
spawnSync(process.execPath, ['--security-revert=not-a-cve']);
assert.strictEqual(signal, null);
assert.strictEqual(status, 12);
assert.strictEqual(
Expand Down

0 comments on commit a6b9299

Please sign in to comment.