ethcore: fix ancient block error msg handling (#8832)
This commit is contained in:
parent
1318f536c9
commit
c8877d4098
@ -2073,15 +2073,16 @@ impl IoClient for Client {
|
|||||||
let first = queued.write().1.pop_front();
|
let first = queued.write().1.pop_front();
|
||||||
if let Some((header, block_bytes, receipts_bytes)) = first {
|
if let Some((header, block_bytes, receipts_bytes)) = first {
|
||||||
let hash = header.hash();
|
let hash = header.hash();
|
||||||
client.importer.import_old_block(
|
let result = client.importer.import_old_block(
|
||||||
&header,
|
&header,
|
||||||
&block_bytes,
|
&block_bytes,
|
||||||
&receipts_bytes,
|
&receipts_bytes,
|
||||||
&**client.db.read(),
|
&**client.db.read(),
|
||||||
&*client.chain.read()
|
&*client.chain.read(),
|
||||||
).ok().map_or((), |e| {
|
);
|
||||||
|
if let Err(e) = result {
|
||||||
error!(target: "client", "Error importing ancient block: {}", e);
|
error!(target: "client", "Error importing ancient block: {}", e);
|
||||||
});
|
}
|
||||||
// remove from pending
|
// remove from pending
|
||||||
queued.write().0.remove(&hash);
|
queued.write().0.remove(&hash);
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user