Commit Graph

2 Commits

Author SHA1 Message Date
Sam Roberts
5dee17bb3c src: rename --security-reverts to ...-revert
It was called --security-revert prior to 12.x, but changed in
https://github.com/nodejs/node/pull/22490.

See:
https://github.com/nodejs/nodejs.org/pull/2412#issuecomment-521739752

PR-URL: https://github.com/nodejs/node/pull/29153
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-08-17 13:32:13 -07:00
Anna Henningsen
38ab1e9ade
src: pass along errors from --security-reverts
Pass along errors from `Revert()` when a security revert
is unknown (which currently applies to all possible values).

Previously, we would unconditionally call `exit()`, which is
not nice for embedding use cases, and could crash because we
were holding a lock for a mutex in `ProcessGlobalArgs()` that
would be destroyed by calling `exit()`.

Also, add a regression test that makes sure that the process
exits with the right exit code and not a crash.

PR-URL: https://github.com/nodejs/node/pull/25466
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-01-22 22:53:26 +01:00