diff -r dfdf85f37215 -r 48f1b314056b mercurial/dispatch.py --- a/mercurial/dispatch.py Tue May 31 04:18:22 2022 +0200 +++ b/mercurial/dispatch.py Tue May 31 16:54:58 2022 +0200 @@ -290,9 +290,8 @@ # maybe pager would quit without consuming all the output, and # SIGPIPE was raised. we cannot print anything in this case. pass - except IOError as inst: - if inst.errno != errno.EPIPE: - raise + except BrokenPipeError: + pass ret = -1 finally: duration = util.timer() - starttime