Skip to content

Commit f07c6ac

Browse files
SomSamantrayaduh95
authored andcommitted
doc: clarify signal listener behavior
Signed-off-by: Som Samantray <[email protected]> PR-URL: #65243 Fixes: #28502 Reviewed-By: Trivikram Kamat <[email protected]>
1 parent fc9364f commit f07c6ac

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

‎doc/api/process.md‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -756,7 +756,8 @@ process.on('SIGTERM', handle);
756756
* `'SIGTERM'` and `'SIGINT'` have default handlers on non-Windows platforms that
757757
reset the terminal mode before exiting with code `128 + signal number`. If one
758758
of these signals has a listener installed, its default behavior will be
759-
removed (Node.js will no longer exit).
759+
removed. Signal events are emitted asynchronously, so Node.js may exit before
760+
the listener is called if the event loop is otherwise empty.
760761
* `'SIGPIPE'` is ignored by default. It can have a listener installed.
761762
* `'SIGHUP'` is generated on Windows when the console window is closed, and on
762763
other platforms under various similar conditions. See signal(7). It can have a

0 commit comments

Comments
 (0)