Stop ignoring errors when disabling SIGPIPE

This commit is contained in:
Jim Paris 2019-08-30 00:16:26 -04:00
parent 9126980ed4
commit 9f2651c35e

View File

@ -136,10 +136,7 @@ class Cmdline(object):
def run(self):
# Set SIGPIPE to its default handler -- we don't need Python
# to catch it for us.
try:
signal.signal(signal.SIGPIPE, signal.SIG_DFL)
except ValueError: # pragma: no cover
pass
signal.signal(signal.SIGPIPE, signal.SIG_DFL)
# Clear cached timezone, so that we can pick up timezone changes
# while running this from the test suite.