Mercurial > public > mercurial-scm > hg
comparison mercurial/hgweb/server.py @ 49304:48f1b314056b
py3: catch BrokenPipeError instead of checking errno == EPIPE
author | Manuel Jacob <me@manueljacob.de> |
---|---|
date | Tue, 31 May 2022 16:54:58 +0200 |
parents | 44b26349127b |
children | fda5a4b853ab 68cf519429ef |
comparison
equal
deleted
inserted
replaced
49303:dfdf85f37215 | 49304:48f1b314056b |
---|---|
113 ) | 113 ) |
114 | 114 |
115 def do_write(self): | 115 def do_write(self): |
116 try: | 116 try: |
117 self.do_hgweb() | 117 self.do_hgweb() |
118 except socket.error as inst: | 118 except BrokenPipeError: |
119 if inst.errno != errno.EPIPE: | 119 pass |
120 raise | |
121 | 120 |
122 def do_POST(self): | 121 def do_POST(self): |
123 try: | 122 try: |
124 self.do_write() | 123 self.do_write() |
125 except Exception as e: | 124 except Exception as e: |