Mercurial > hg
changeset 35985:e69e65b2b4a9
hgweb: move call to protocol handler outside of try..except
The protocol handler doesn't raise ErrorResponse. So it doesn't
need to be in this `try..except ErrorResponse` block.
Differential Revision: https://phab.mercurial-scm.org/D2020
author | Gregory Szorc <gregory.szorc@gmail.com> |
---|---|
date | Wed, 31 Jan 2018 16:43:46 -0800 |
parents | cdc93fe1da77 |
children | 98a00aa0288d |
files | mercurial/hgweb/hgweb_mod.py |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/hgweb/hgweb_mod.py Wed Jan 31 16:21:43 2018 -0800 +++ b/mercurial/hgweb/hgweb_mod.py Wed Jan 31 16:43:46 2018 -0800 @@ -368,7 +368,6 @@ raise ErrorResponse(HTTP_NOT_FOUND) if cmd in perms: self.check_perm(rctx, req, perms[cmd]) - return protohandler['dispatch']() except ErrorResponse as inst: # A client that sends unbundle without 100-continue will # break if we respond early. @@ -383,6 +382,8 @@ body='0\n%s\n' % inst) return '' + return protohandler['dispatch']() + # translate user-visible url structure to internal structure args = query.split('/', 2)