doc: note that default signal handling resets the signal mask

`InitializeOncePerProcess()` without `kNoDefaultSignalHandling` calls
`pthread_sigmask(SIG_SETMASK, ...)` with a set containing only SIGUSR1,
which unblocks every signal the embedder had blocked on the calling
thread. Say so in the flag's documentation.

Refs: https://github.com/nodejs/node/pull/44121
Signed-off-by: Shelley Vohr <shelley.vohr@gmail.com>
PR-URL: https://github.com/nodejs/node/pull/65877
Refs: https://github.com/nodejs/node/pull/25777
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
This commit is contained in:
Shelley Vohr authored and Antoine du Hamel committed 2026-09-16 21:12:18 +02:00
1 parent 95110712b8
commit 2cc17dd67c
1 file changed
+4 -2
+4 -2
View File
@@ -210,8 +210,10 @@ enum Flags : uint32_t {
kNoICU = 1 << 3,
// Do not modify stdio file descriptor or TTY state.
kNoStdioInitialization = 1 << 4,
// Do not register Node.js-specific signal handlers
// and reset other signal handlers to default state.
// Do not register Node.js-specific signal handlers, reset other signal
// handlers to default state, or replace the calling thread's signal mask
// (without this flag, POSIX builds with the inspector set it to block
// SIGUSR1 and nothing else).
kNoDefaultSignalHandling = 1 << 5,
// Do not perform V8 initialization.
kNoInitializeV8 = 1 << 6,