mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-06-16 11:51:35 +00:00
delete buffer when validation failed
This commit is contained in:
parent
48da785c86
commit
7609febf20
1 changed files with 1 additions and 0 deletions
|
|
@ -458,6 +458,7 @@ func (p *Peer) bufferReceipts(requestId uint64, receiptLists []*ReceiptList69, l
|
||||||
gasUsed := buffer.gasUsed[lastBlock]
|
gasUsed := buffer.gasUsed[lastBlock]
|
||||||
logSize, err := p.validateLastBlockReceipt(receiptLists, requestId, gasUsed)
|
logSize, err := p.validateLastBlockReceipt(receiptLists, requestId, gasUsed)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
delete(p.receiptBuffer, requestId)
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
// Update the buffered data and trim the packet to exclude the incomplete block.
|
// Update the buffered data and trim the packet to exclude the incomplete block.
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue