mirror of
https://github.com/romanz/electrs.git
synced 2024-11-19 09:54:09 +01:00
Don't crash on orphan blocks
This commit is contained in:
parent
4a8f7b5c0b
commit
e14f7f7174
@ -63,7 +63,9 @@ impl HeaderList {
|
||||
hashed_headers.push_front(HashedHeader { blockhash, header });
|
||||
blockhash = header.prev_blockhash;
|
||||
}
|
||||
assert!(header_map.is_empty());
|
||||
if !header_map.is_empty() {
|
||||
warn!("orphaned blocks: {:?}", header_map);
|
||||
}
|
||||
HeaderList {
|
||||
headers: hashed_headers
|
||||
.into_iter()
|
||||
|
Loading…
Reference in New Issue
Block a user