mercurial/revlog.py
branchstable
changeset 41302 c953c2a94d68
parent 41301 13c23396c7fe
child 41310 ab0d762d89ef
--- a/mercurial/revlog.py	Sun Jan 20 11:57:36 2019 +0900
+++ b/mercurial/revlog.py	Mon Jan 21 22:14:29 2019 +0900
@@ -396,6 +396,11 @@
             newversionflags = REVLOGV1 | FLAG_INLINE_DATA
             if 'generaldelta' in opts:
                 newversionflags |= FLAG_GENERALDELTA
+        elif getattr(self.opener, 'options', None) is not None:
+            # If options provided but no 'revlog*' found, the repository
+            # would have no 'requires' file in it, which means we have to
+            # stick to the old format.
+            newversionflags = REVLOGV0
         else:
             newversionflags = REVLOG_DEFAULT_VERSION