Show More
@@ -328,15 +328,19 b' class revlog(object):' | |||
|
328 | 328 | self._generaldelta = v & FLAG_GENERALDELTA |
|
329 | 329 | flags = v & ~0xFFFF |
|
330 | 330 | fmt = v & 0xFFFF |
|
331 |
if fmt == REVLOGV0 |
|
|
332 | raise RevlogError(_("index %s unknown flags %#04x for format v0") | |
|
333 | % (self.indexfile, flags >> 16)) | |
|
334 | elif fmt == REVLOGV1 and flags & ~REVLOGV1_FLAGS: | |
|
335 | raise RevlogError(_("index %s unknown flags %#04x for revlogng") | |
|
336 | % (self.indexfile, flags >> 16)) | |
|
337 |
|
|
|
338 |
raise RevlogError(_( |
|
|
339 |
% |
|
|
331 | if fmt == REVLOGV0: | |
|
332 | if flags: | |
|
333 | raise RevlogError(_('unknown flags (%#04x) in version %d ' | |
|
334 | 'revlog %s') % | |
|
335 | (flags >> 16, fmt, self.indexfile)) | |
|
336 | elif fmt == REVLOGV1: | |
|
337 | if flags & ~REVLOGV1_FLAGS: | |
|
338 | raise RevlogError(_('unknown flags (%#04x) in version %d ' | |
|
339 | 'revlog %s') % | |
|
340 | (flags >> 16, fmt, self.indexfile)) | |
|
341 | else: | |
|
342 | raise RevlogError(_('unknown version (%d) in revlog %s') % | |
|
343 | (fmt, self.indexfile)) | |
|
340 | 344 | |
|
341 | 345 | self.storedeltachains = True |
|
342 | 346 |
@@ -5,7 +5,7 b'' | |||
|
5 | 5 | $ hg commit -m test |
|
6 | 6 | $ rm .hg/requires |
|
7 | 7 | $ hg tip |
|
8 | abort: index 00changelog.i unknown format 2! | |
|
8 | abort: unknown version (2) in revlog 00changelog.i! | |
|
9 | 9 | [255] |
|
10 | 10 |
$ |
|
11 | 11 | $ hg tip |
@@ -7,7 +7,7 b' Flags on revlog version 0 are rejected' | |||
|
7 | 7 | ... fh.write('\x00\x01\x00\x00') |
|
8 | 8 | |
|
9 | 9 | $ hg log |
|
10 | abort: index 00changelog.i unknown flags 0x01 for format v0! | |
|
10 | abort: unknown flags (0x01) in version 0 revlog 00changelog.i! | |
|
11 | 11 | [255] |
|
12 | 12 | |
|
13 | 13 | Unknown flags on revlog version 1 are rejected |
@@ -16,7 +16,7 b' Unknown flags on revlog version 1 are re' | |||
|
16 | 16 | ... fh.write('\x00\x04\x00\x01') |
|
17 | 17 | |
|
18 | 18 | $ hg log |
|
19 |
abort: |
|
|
19 | abort: unknown flags (0x04) in version 1 revlog 00changelog.i! | |
|
20 | 20 | [255] |
|
21 | 21 | |
|
22 | 22 | Unknown version is rejected |
@@ -25,7 +25,7 b' Unknown version is rejected' | |||
|
25 | 25 | ... fh.write('\x00\x00\x00\x02') |
|
26 | 26 | |
|
27 | 27 | $ hg log |
|
28 | abort: index 00changelog.i unknown format 2! | |
|
28 | abort: unknown version (2) in revlog 00changelog.i! | |
|
29 | 29 | [255] |
|
30 | 30 | |
|
31 | 31 |
$ |
General Comments 0
You need to be logged in to leave comments.
Login now