Thu, 24 Jul 2008 22:35:38 -0400
Use the default action for SIGPIPE.
Using Python's built-in handler makes weird error messages for the user,
and there's no reason not to act like every other Unix program in this
regard. This seems particularly true since we're most likely to get
SIGPIPE with dtrx -l, where we won't write things to disk etc.
scripts/dtrx | file | annotate | diff | comparison | revisions |
--- a/scripts/dtrx Thu Jul 24 22:15:19 2008 -0400 +++ b/scripts/dtrx Thu Jul 24 22:35:38 2008 -0400 @@ -991,6 +991,7 @@ def __init__(self, arguments): for signal_num in (signal.SIGINT, signal.SIGTERM): signal.signal(signal_num, self.abort) + signal.signal(signal.SIGPIPE, signal.SIG_DFL) self.parse_options(arguments) self.setup_logger() self.successes = []