Jonathan Oddy
f2dccb90e8
Restore SIGPIPE handler to DFL on POpen
...
Python sets the SIGPIPE handler to SIG_IGN. On execv() signal handlers are
reset to their defaults, EXCEPT those that are SIG_IGN which are left ignored.
In Python 3 subprocess.popen explicitly resets the SIGPIPE handler to SIG_DFL,
but unfortunately in Python 2.7 it does not. This leads to subprocesses being
executed with SIGPIPE ignored. This is often a problem with bash scripts which
rely on SIGPIPE to terminate commands in a pipe, but can easily be a problem
with other applications.
This implements the Python 3 behaviour for Python 2.7 by using a preexec_fn.
2018-10-12 12:31:24 -07:00
..
2018-10-04 16:53:32 -04:00
2018-10-08 11:26:37 -07:00
2018-07-17 11:37:23 -07:00
2018-10-02 15:55:53 -07:00
2018-10-12 10:23:03 +02:00
2018-10-12 05:11:48 -04:00
2018-08-22 21:53:30 +02:00
2018-10-11 09:49:49 -04:00
2018-02-12 13:05:38 -05:00
2018-10-02 15:55:53 -07:00
2017-12-14 19:38:35 +01:00
2018-07-31 12:06:56 -07:00
2018-08-09 10:38:26 -07:00
2017-11-30 15:47:38 -08:00
2017-07-24 09:19:04 -07:00
2018-09-28 09:12:31 +01:00
2018-05-17 11:41:14 -04:00
2018-08-02 11:17:39 -04:00
2017-08-07 19:46:06 -07:00
2018-05-23 16:55:57 -07:00
2018-10-05 07:02:44 -04:00
2018-10-12 12:31:24 -07:00
2017-08-22 15:31:20 -04:00
2017-12-11 14:48:35 +00:00
2018-05-21 17:16:44 +02:00
2018-09-24 09:09:17 -04:00
2017-12-12 12:35:22 +00:00
2018-07-31 12:06:56 -07:00
2018-03-01 09:56:53 +05:30
2018-02-07 00:44:42 +01:00
2018-10-06 08:50:31 -05:00
2018-09-05 13:34:26 -04:00
2018-02-05 22:40:02 +01:00
2017-12-03 21:42:30 +05:30
2018-04-30 15:33:28 -05:00
2017-06-02 12:14:11 +01:00
2017-06-02 12:14:11 +01:00
2018-08-30 10:27:29 -04:00
2018-08-31 08:28:32 -04:00
2018-05-22 14:25:36 -07:00
2018-05-22 11:50:53 +02:00
2018-08-15 08:38:11 +02:00
2017-06-02 12:14:11 +01:00
2018-04-15 22:05:51 -04:00
2018-08-26 23:18:46 +05:30
2018-08-10 11:13:29 -05:00
2018-01-31 13:12:53 +00:00
2017-11-21 10:03:34 -08:00
2018-08-21 16:32:37 +02:00
2018-08-10 11:13:29 -05:00
2018-05-22 14:25:36 -07:00
2018-05-25 00:30:25 +02:00
2018-09-19 08:44:05 -07:00
2018-08-10 09:33:08 -07:00
2018-08-10 09:33:08 -07:00
2018-08-28 13:00:19 +01:00
2018-02-07 12:15:27 -06:00
2018-10-08 11:26:37 -07:00
2018-09-24 21:03:50 +02:00
2018-08-27 10:55:04 -04:00
2018-06-04 10:18:15 +02:00
2018-10-08 11:26:37 -07:00
2017-08-12 00:48:53 -07:00
2018-02-22 15:33:48 -05:00
2018-07-31 12:06:56 -07:00
2018-10-10 09:55:08 +05:30
2017-11-21 10:03:34 -08:00
2018-10-11 14:17:13 -04:00
2017-09-13 01:53:08 -07:00
2018-10-01 12:37:48 +01:00
2018-07-31 13:23:05 -04:00
2017-06-02 12:14:11 +01:00
2018-01-10 14:08:11 -08:00
2018-10-08 14:41:57 +02:00
2017-08-14 12:40:06 -04:00
2018-05-07 16:30:16 +05:30
2018-09-11 09:58:53 +05:30
2018-09-19 00:01:53 +02:00
2018-10-10 18:49:24 -04:00