[PATCH 2 of 2 STABLE] sparse-revlog: unconditionally enables general delta

Boris Feld boris.feld at octobus.net
Mon Jul 30 10:21:23 EDT 2018


# HG changeset patch
# User Boris Feld <boris.feld at octobus.net>
# Date 1532958737 -7200
#      Mon Jul 30 15:52:17 2018 +0200
# Branch stable
# Node ID ea0704e5b98147dc9af5c9cfeadb8b20b5cf00b2
# Parent  7f3c63990b6160517a70b896bb9499d1daea2ded
# EXP-Topic sparse-revlog
# Available At https://bitbucket.org/octobus/mercurial-devel/
#              hg pull https://bitbucket.org/octobus/mercurial-devel/ -r ea0704e5b981
sparse-revlog: unconditionally enables general delta

This come as an extra security, better safe than sorry.

diff --git a/mercurial/localrepo.py b/mercurial/localrepo.py
--- a/mercurial/localrepo.py
+++ b/mercurial/localrepo.py
@@ -689,6 +689,8 @@ class localrepository(object):
         self.svfs.options['sparse-read-min-gap-size'] = srmingapsize
         sparserevlog = SPARSEREVLOG_REQUIREMENT in self.requirements
         self.svfs.options['sparse-revlog'] = sparserevlog
+        if sparserevlog:
+            self.svfs.options['generaldelta'] = True
 
         for r in self.requirements:
             if r.startswith('exp-compression-'):


More information about the Mercurial-devel mailing list