diff --git a/mercurial/copies.py b/mercurial/copies.py --- a/mercurial/copies.py +++ b/mercurial/copies.py @@ -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()