Comments
Patch
@@ -193,6 +193,8 @@
ui.warn(_(" empty string\n"))
else:
ui.warn("\n%r\n" % util.ellipsis(inst.args[1]))
+ except error.CensoredNodeError, inst:
+ ui.warn(_("abort: file censored %s!\n") % inst)
except error.RevlogError, inst:
ui.warn(_("abort: %s!\n") % inst)
except error.SignalInterrupt:
@@ -117,3 +117,9 @@
"""error raised when code tries to alter a part being generated"""
pass
+class CensoredNodeError(RevlogError):
+ """error raised when content verification fails on a censored node"""
+
+ def __init__(self, filename, node):
+ from node import short
+ RevlogError.__init__(self, '%s:%s' % (filename, short(node)))