Show More
@@ -33,7 +33,7 b' def _parsev1(data):' | |||||
33 | # class exactly matches its C counterpart to try and help |
|
33 | # class exactly matches its C counterpart to try and help | |
34 | # prevent surprise breakage for anyone that develops against |
|
34 | # prevent surprise breakage for anyone that develops against | |
35 | # the pure version. |
|
35 | # the pure version. | |
36 | if data and data[-1] != '\n': |
|
36 | if data and data[-1:] != '\n': | |
37 | raise ValueError('Manifest did not end in a newline.') |
|
37 | raise ValueError('Manifest did not end in a newline.') | |
38 | prev = None |
|
38 | prev = None | |
39 | for l in data.splitlines(): |
|
39 | for l in data.splitlines(): | |
@@ -55,7 +55,7 b' def _parsev2(data):' | |||||
55 | end = data.find('\n', pos + 1) # +1 to skip stem length byte |
|
55 | end = data.find('\n', pos + 1) # +1 to skip stem length byte | |
56 | if end == -1: |
|
56 | if end == -1: | |
57 | raise ValueError('Manifest ended with incomplete file entry.') |
|
57 | raise ValueError('Manifest ended with incomplete file entry.') | |
58 | stemlen = ord(data[pos]) |
|
58 | stemlen = ord(data[pos:pos + 1]) | |
59 | items = data[pos + 1:end].split('\0') |
|
59 | items = data[pos + 1:end].split('\0') | |
60 | f = prevf[:stemlen] + items[0] |
|
60 | f = prevf[:stemlen] + items[0] | |
61 | if prevf > f: |
|
61 | if prevf > f: |
General Comments 0
You need to be logged in to leave comments.
Login now