martinvonz created this revision. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers.
REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D7140 AFFECTED FILES hgext/largefiles/lfutil.py CHANGE DETAILS diff --git a/hgext/largefiles/lfutil.py b/hgext/largefiles/lfutil.py --- a/hgext/largefiles/lfutil.py +++ b/hgext/largefiles/lfutil.py @@ -41,9 +41,9 @@ @contextlib.contextmanager -def lfstatus(repo): +def lfstatus(repo, value=True): oldvalue = getattr(repo, 'lfstatus', False) - repo.lfstatus = True + repo.lfstatus = value try: yield finally: @@ -591,12 +591,8 @@ progress.update(i) parents = [p for p in repo[n].parents() if p != node.nullid] - oldlfstatus = repo.lfstatus - repo.lfstatus = False - try: + with lfstatus(repo, value=False): ctx = repo[n] - finally: - repo.lfstatus = oldlfstatus files = set(ctx.files()) if len(parents) == 2: To: martinvonz, #hg-reviewers Cc: mercurial-devel _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel