manifest: use read_delta_new_entries in changegroup validate
This new method have a well defined semantic and can be adjusted by narrow as it
needs. This should prevent some unwanted filelog access when running validate on
a server using narrow profile to restrict access.
--- a/mercurial/changegroup.py Tue Aug 06 02:12:08 2024 +0200
+++ b/mercurial/changegroup.py Tue Aug 06 02:13:17 2024 +0200
@@ -611,7 +611,7 @@
# validate incoming csets have their manifests
for cset in range(clstart, clend):
mfnode = cl.changelogrevision(cset).manifest
- mfest = ml[mfnode].readdelta()
+ mfest = ml[mfnode].read_delta_new_entries()
# store file nodes we must see
for f, n in mfest.items():
needfiles.setdefault(f, set()).add(n)