mirror of
https://github.com/kovidgoyal/kitty.git
synced 2024-11-10 13:04:03 +03:00
Fix a regression that caused kitty not to restore SIGPIPE after python nukes it when launching children. Affects bash which does not sanitize its signal mask.
Fixes #5500
This commit is contained in:
parent
fe2f3d9870
commit
bcd78c3940
@ -55,6 +55,8 @@ Detailed list of changes
|
||||
|
||||
- Wayland: Generate a XDG_ACTIVATION_TOKEN when opening URLs or running programs in the background via the launch action
|
||||
|
||||
- Fix a regression that caused kitty not to restore SIGPIPE after python nukes it when launching children. Affects bash which does not sanitize its signal mask. (:iss:`5500`)
|
||||
|
||||
|
||||
0.26.2 [2022-09-05]
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
@ -100,11 +100,14 @@ spawn(PyObject *self UNUSED, PyObject *args) {
|
||||
#if PY_VERSION_HEX >= 0x03070000
|
||||
PyOS_AfterFork_Child();
|
||||
#endif
|
||||
// See _Py_RestoreSignals in signalmodule.c for a list of signals python nukes
|
||||
const struct sigaction act = {.sa_handler=SIG_DFL};
|
||||
|
||||
#define SA(which) if (sigaction(which, &act, NULL) != 0) exit_on_err("sigaction() in child process failed");
|
||||
for (int si = 0; si < num_handled_signals; si++) { SA(handled_signals[si]); }
|
||||
// See _Py_RestoreSignals in signalmodule.c for a list of signals python nukes
|
||||
#ifdef SIGPIPE
|
||||
SA(SIGPIPE)
|
||||
#endif
|
||||
#ifdef SIGXFSZ
|
||||
SA(SIGXFSZ);
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user