tag: do not pass binary nullid to scmutil.revsingle()
authorYuya Nishihara <yuya@tcha.org>
Sun, 15 Mar 2015 14:45:26 +0900
changeset 25903 9bbab9decd71
parent 25902 5214cbdc37e5
child 25904 fbaa2de13cf6
tag: do not pass binary nullid to scmutil.revsingle() Future patches will remove the old-style parser that happen to accept a binary nodeid. A binary nodeid shouldn't be passed to scmutil.revrange() because it is ambiguous. For example, bin('20' * 19 + '30') is valid binary nodeid, but it can also be parsed as a revset expression, '0'.
mercurial/commands.py
--- a/mercurial/commands.py	Sat Jul 18 23:30:17 2015 +0900
+++ b/mercurial/commands.py	Sun Mar 15 14:45:26 2015 +0900
@@ -6248,7 +6248,7 @@
                         raise util.Abort(_("tag '%s' is not a global tag") % n)
                     else:
                         raise util.Abort(_("tag '%s' is not a local tag") % n)
-            rev_ = nullid
+            rev_ = 'null'
             if not message:
                 # we don't translate commit messages
                 message = 'Removed tag %s' % ', '.join(names)