Site
Gitweb
Static
projects
/
eros.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4ecdc84
)
Fix verify output range merge bug (disk block unaligned pieces)
master
author
Jakob Cornell
<jakob+gpg@jcornell.net>
Sun, 21 Aug 2022 15:31:39 +0000
(10:31 -0500)
committer
Jakob Cornell
<jakob+gpg@jcornell.net>
Sun, 21 Aug 2022 15:31:39 +0000
(10:31 -0500)
disk_jumble/src/disk_jumble/verify.py
patch
|
blob
|
history
diff --git
a/disk_jumble/src/disk_jumble/verify.py
b/disk_jumble/src/disk_jumble/verify.py
index 19cf1a75a771b837d6161e3dd40823235164fc57..5229f516150d850fa10ce9a6f7e1c51e368e606c 100644
(file)
--- a/
disk_jumble/src/disk_jumble/verify.py
+++ b/
disk_jumble/src/disk_jumble/verify.py
@@
-359,7
+359,9
@@
def _do_verify(
def clean_up(ranges):
out = []
for r in sorted(ranges, key = lambda r: r.start):
- if out and r.start == out[-1].stop:
+ if out:
+ assert r.start >= out[-1].stop - 1
+ if out and r.start <= out[-1].stop:
out[-1] = range(out[-1].start, r.stop)
else:
out.append(r)