changeset 41232:f3f5bfbf7e04

copies: use node.nullrev instead of literal -1 Differential Revision: https://phab.mercurial-scm.org/D5593
author Martin von Zweigbergk <martinvonz@google.com>
date Tue, 15 Jan 2019 11:07:34 -0800
parents e3e1b0639375
children 92b3811fd15f
files mercurial/copies.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/copies.py	Tue Jan 15 09:20:47 2019 -0800
+++ b/mercurial/copies.py	Tue Jan 15 11:07:34 2019 -0800
@@ -131,7 +131,7 @@
 
     return t
 
-def _tracefile(fctx, am, limit=-1):
+def _tracefile(fctx, am, limit=node.nullrev):
     """return file context that is the ancestor of fctx present in ancestor
     manifest am, stopping after the first ancestor lower than limit"""
 
@@ -170,7 +170,7 @@
             % (a, b))
     limit = _findlimit(repo, a.rev(), b.rev())
     if limit is None:
-        limit = -1
+        limit = node.nullrev
     if debug:
         dbg('debug.copies:      search limit: %d\n' % limit)
     am = a.manifest()