changeset 45247:e15416c95b25

commitctx: explicitly pass `manifest` to _commit_manifest As pointed out by Yuya Nishihara.
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Wed, 29 Jul 2020 15:40:13 +0200
parents b1f2659c1c34
children 4cde23ba076e
files mercurial/commit.py
diffstat 1 files changed, 2 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/commit.py	Thu Jul 30 16:58:38 2020 +0100
+++ b/mercurial/commit.py	Wed Jul 29 15:40:13 2020 +0200
@@ -206,7 +206,7 @@
     touched.extend(removed)
 
     files = touched
-    mn = _commit_manifest(tr, linkrev, ctx, mctx, files, added, drop)
+    mn = _commit_manifest(tr, linkrev, ctx, mctx, m, files, added, drop)
 
     return mn, files, filesadded, removed
 
@@ -347,7 +347,7 @@
     return fnode, touched
 
 
-def _commit_manifest(tr, linkrev, ctx, mctx, files, added, drop):
+def _commit_manifest(tr, linkrev, ctx, mctx, manifest, files, added, drop):
     """make a new manifest entry (or reuse a new one)
 
     given an initialised manifest context and precomputed list of
@@ -370,8 +370,6 @@
 
     m1 = m1ctx.read()
 
-    manifest = mctx.read()
-
     if not files:
         # if no "files" actually changed in terms of the changelog,
         # try hard to detect unmodified manifest entry so that the