mirror of
https://github.com/google/leveldb.git
synced 2025-06-11 12:43:19 +08:00
Fix skipping the trailer
This commit is contained in:
parent
4fb146810c
commit
030a09159b
@ -35,7 +35,7 @@ bool Reader::SkipToInitialBlock() {
|
|||||||
uint64_t block_start_location = initial_offset_ - offset_in_block;
|
uint64_t block_start_location = initial_offset_ - offset_in_block;
|
||||||
|
|
||||||
// Don't search a block if we'd be in the trailer
|
// Don't search a block if we'd be in the trailer
|
||||||
if (offset_in_block > kBlockSize - 6) {
|
if (offset_in_block >= kBlockSize - 6) {
|
||||||
block_start_location += kBlockSize;
|
block_start_location += kBlockSize;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user