This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ntrrgc
Recipients ntrrgc
Date 2018-03-02.17:31:25
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1520011885.85.0.467229070634.issue32985@psf.upfronthosting.co.za>
In-reply-to
Content
The docs state:

> If restore_signals is true (the default) all signals that Python has set to SIG_IGN are restored to SIG_DFL in the child process before the exec. Currently this includes the SIGPIPE, SIGXFZ and SIGXFSZ signals. (POSIX only)

The first phrase and the second may seem contradictory for anyone that uses signal handling in their code.

I would definitely not describe the set of "SIGPIPE, SIGXFZ and SIGXFSZ" as "all signals that Python has set". It actually means "all the signals that Python set at startup"; the user could have changed different signals than these (e.g. SIGINT) for various purposes (e.g. not getting a KeyboardInterrupt while an interactive process is running).

The current wording may suggest that all signals changed by the user are reset in the child process, but this is not the case -- I could confirm by looking at _Py_RestoreSignals(). Only these three specific signals are restored.
History
Date User Action Args
2018-03-02 17:31:25ntrrgcsetrecipients: + ntrrgc
2018-03-02 17:31:25ntrrgcsetmessageid: <1520011885.85.0.467229070634.issue32985@psf.upfronthosting.co.za>
2018-03-02 17:31:25ntrrgclinkissue32985 messages
2018-03-02 17:31:25ntrrgccreate