Show More
@@ -1156,7 +1156,7 b' class revlog:' | |||||
1156 | return self.index[rev][1] |
|
1156 | return self.index[rev][1] | |
1157 |
|
1157 | |||
1158 | def sidedata_length(self, rev): |
|
1158 | def sidedata_length(self, rev): | |
1159 | if not self.hassidedata: |
|
1159 | if not self.feature_config.has_side_data: | |
1160 | return 0 |
|
1160 | return 0 | |
1161 | return self.index[rev][9] |
|
1161 | return self.index[rev][9] | |
1162 |
|
1162 | |||
@@ -2565,7 +2565,7 b' class revlog:' | |||||
2565 |
|
2565 | |||
2566 | if sidedata is None: |
|
2566 | if sidedata is None: | |
2567 | sidedata = {} |
|
2567 | sidedata = {} | |
2568 | elif sidedata and not self.hassidedata: |
|
2568 | elif sidedata and not self.feature_config.has_side_data: | |
2569 | raise error.ProgrammingError( |
|
2569 | raise error.ProgrammingError( | |
2570 | _(b"trying to add sidedata to a revlog who don't support them") |
|
2570 | _(b"trying to add sidedata to a revlog who don't support them") | |
2571 | ) |
|
2571 | ) | |
@@ -2824,7 +2824,7 b' class revlog:' | |||||
2824 | compression_mode, deltainfo = r |
|
2824 | compression_mode, deltainfo = r | |
2825 |
|
2825 | |||
2826 | sidedata_compression_mode = COMP_MODE_INLINE |
|
2826 | sidedata_compression_mode = COMP_MODE_INLINE | |
2827 | if sidedata and self.hassidedata: |
|
2827 | if sidedata and self.feature_config.has_side_data: | |
2828 | sidedata_compression_mode = COMP_MODE_PLAIN |
|
2828 | sidedata_compression_mode = COMP_MODE_PLAIN | |
2829 | serialized_sidedata = sidedatautil.serialize_sidedata(sidedata) |
|
2829 | serialized_sidedata = sidedatautil.serialize_sidedata(sidedata) | |
2830 | sidedata_offset = self._docket.sidedata_end |
|
2830 | sidedata_offset = self._docket.sidedata_end | |
@@ -3640,7 +3640,7 b' class revlog:' | |||||
3640 | return d |
|
3640 | return d | |
3641 |
|
3641 | |||
3642 | def rewrite_sidedata(self, transaction, helpers, startrev, endrev): |
|
3642 | def rewrite_sidedata(self, transaction, helpers, startrev, endrev): | |
3643 | if not self.hassidedata: |
|
3643 | if not self.feature_config.has_side_data: | |
3644 | return |
|
3644 | return | |
3645 | # revlog formats with sidedata support does not support inline |
|
3645 | # revlog formats with sidedata support does not support inline | |
3646 | assert not self._inline |
|
3646 | assert not self._inline | |
@@ -3669,7 +3669,7 b' class revlog:' | |||||
3669 | ) |
|
3669 | ) | |
3670 |
|
3670 | |||
3671 | sidedata_compression_mode = COMP_MODE_INLINE |
|
3671 | sidedata_compression_mode = COMP_MODE_INLINE | |
3672 | if serialized_sidedata and self.hassidedata: |
|
3672 | if serialized_sidedata and self.feature_config.has_side_data: | |
3673 | sidedata_compression_mode = COMP_MODE_PLAIN |
|
3673 | sidedata_compression_mode = COMP_MODE_PLAIN | |
3674 | h, comp_sidedata = self.compress(serialized_sidedata) |
|
3674 | h, comp_sidedata = self.compress(serialized_sidedata) | |
3675 | if ( |
|
3675 | if ( |
@@ -42,7 +42,7 b' def wrap_revisiondata(orig, self, nodeor' | |||||
42 | sd = self.sidedata(nodeorrev) |
|
42 | sd = self.sidedata(nodeorrev) | |
43 | if getattr(self, 'sidedatanocheck', False): |
|
43 | if getattr(self, 'sidedatanocheck', False): | |
44 | return text |
|
44 | return text | |
45 | if self.hassidedata: |
|
45 | if self.feature_config.has_side_data: | |
46 | return text |
|
46 | return text | |
47 | if nodeorrev != nullrev and nodeorrev != self.nullid: |
|
47 | if nodeorrev != nullrev and nodeorrev != self.nullid: | |
48 | cat1 = sd.get(sidedata.SD_TEST1) |
|
48 | cat1 = sd.get(sidedata.SD_TEST1) |
General Comments 0
You need to be logged in to leave comments.
Login now