mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 02:12:23 +00:00
fix call flat receipt
Signed-off-by: jsvisa <delweng@gmail.com>
This commit is contained in:
parent
d9e7cef0c1
commit
7d351600b6
1 changed files with 9 additions and 6 deletions
|
|
@ -211,14 +211,17 @@ func (t *flatCallTracer) OnTxStart(env *tracing.VMContext, tx *types.Transaction
|
|||
}
|
||||
|
||||
func (t *flatCallTracer) OnTxEnd(receipt *types.Receipt, err error) {
|
||||
if t.interrupt.Load() {
|
||||
return
|
||||
}
|
||||
// Set the context for the tracer only if receipt is available and no error occured
|
||||
if err == nil && receipt != nil {
|
||||
t.ctx = &tracers.Context{
|
||||
BlockHash: receipt.BlockHash,
|
||||
BlockNumber: receipt.BlockNumber,
|
||||
TxIndex: int(receipt.TransactionIndex),
|
||||
TxHash: receipt.TxHash,
|
||||
}
|
||||
if t.interrupt.Load() {
|
||||
return
|
||||
}
|
||||
t.tracer.OnTxEnd(receipt, err)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue