mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-20 02:42:27 +00:00
check tx receipt status
This commit is contained in:
parent
2ed47cf48e
commit
3c7ced7e1e
2 changed files with 13 additions and 1 deletions
|
|
@ -867,6 +867,19 @@ func (c *Posv) Finalize(chain consensus.ChainReader, header *types.Header, state
|
||||||
blkHash := common.BytesToHash(tx.Data()[len(tx.Data())-32:])
|
blkHash := common.BytesToHash(tx.Data()[len(tx.Data())-32:])
|
||||||
from := *tx.From()
|
from := *tx.From()
|
||||||
|
|
||||||
|
var b uint
|
||||||
|
for _, r := range receipts {
|
||||||
|
if r.TxHash == tx.Hash() {
|
||||||
|
b = r.Status
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if b == types.ReceiptStatusFailed {
|
||||||
|
fmt.Println("Tx receipt status false")
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
var lAddr []common.Address
|
var lAddr []common.Address
|
||||||
if cached, ok := c.BlockSigners.Get(blkHash); ok {
|
if cached, ok := c.BlockSigners.Get(blkHash); ok {
|
||||||
lAddr = cached.([]common.Address)
|
lAddr = cached.([]common.Address)
|
||||||
|
|
|
||||||
|
|
@ -397,7 +397,6 @@ func GetRewardForCheckpoint(c *posv.Posv, chain consensus.ChainReader, blockSign
|
||||||
|
|
||||||
wg.Wait()
|
wg.Wait()
|
||||||
}
|
}
|
||||||
fmt.Println("c.BlockSigners.Len()", c.BlockSigners.Len())
|
|
||||||
fmt.Println("totalSigner", *totalSigner)
|
fmt.Println("totalSigner", *totalSigner)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue