branch | stable |
changeset 10951 | 5dc09507b90e |
parent 10531 | e3eff76552f1 |
child 11370 | db3f6f0e4e7d |
--- a/mercurial/hgweb/protocol.py Thu Mar 04 14:32:01 2010 -0600 +++ b/mercurial/hgweb/protocol.py Thu Apr 01 22:04:30 2010 +0100 @@ -179,6 +179,8 @@ raise ErrorResponse(HTTP_OK, inst) except (OSError, IOError), inst: error = getattr(inst, 'strerror', 'Unknown error') + if not isinstance(error, str): + error = 'Error: %s' % str(error) if inst.errno == errno.ENOENT: code = HTTP_NOT_FOUND else: