diff -r 1a786fe069b8 -r 17ca967e9fca mercurial/hgweb/hgweb_mod.py --- a/mercurial/hgweb/hgweb_mod.py Fri Sep 07 22:19:28 2018 +0900 +++ b/mercurial/hgweb/hgweb_mod.py Sun Aug 26 22:23:25 2018 +0900 @@ -439,6 +439,10 @@ res.status = '500 Internal Server Error' res.headers['Content-Type'] = ctype return rctx.sendtemplate('error', error=pycompat.bytestr(e)) + except error.Abort as e: + res.status = '403 Forbidden' + res.headers['Content-Type'] = ctype + return rctx.sendtemplate('error', error=pycompat.bytestr(e)) except ErrorResponse as e: for k, v in e.headers: res.headers[k] = v