hg-core: minor code style change (D8958#inline-14993 followup)
Differential Revision: https://phab.mercurial-scm.org/D9083
--- a/rust/hg-core/src/revlog/index.rs Thu Sep 24 09:32:07 2020 +0200
+++ b/rust/hg-core/src/revlog/index.rs Mon Sep 28 13:46:14 2020 +0200
@@ -21,7 +21,7 @@
let mut offset: usize = 0;
let mut offsets = Vec::new();
- while (bytes.len() - offset) >= INDEX_ENTRY_SIZE {
+ while offset + INDEX_ENTRY_SIZE <= bytes.len() {
offsets.push(offset);
let end = offset + INDEX_ENTRY_SIZE;
let entry = IndexEntry {