# HG changeset patch # User Greg Ward # Date 2010-04-13 21:58:38 # Node ID cf016c9831d1c42cdadebe7042b5fd592a66a3eb # Parent 90112473b8ca6b258b646a6a4f332beaca738550 revlog: factor out _maxinline global. This lets us change the threshold at which a *.d file will be split out, which should make it much easier to construct test cases that probe revlogs with a separate data file. (issue2137) diff --git a/mercurial/revlog.py b/mercurial/revlog.py --- a/mercurial/revlog.py +++ b/mercurial/revlog.py @@ -33,6 +33,8 @@ REVLOG_DEFAULT_VERSION = REVLOG_DEFAULT_ _prereadsize = 1048576 +_maxinline = 131072 # max size of revlog with inline data + RevlogError = error.RevlogError LookupError = error.LookupError @@ -1036,7 +1038,7 @@ class revlog(object): return text def checkinlinesize(self, tr, fp=None): - if not self._inline or (self.start(-2) + self.length(-2)) < 131072: + if not self._inline or (self.start(-2) + self.length(-2)) < _maxinline: return trinfo = tr.find(self.indexfile)