From d3e3a460ec947c9e1e963d1a35f887d95f23f99d Mon Sep 17 00:00:00 2001 From: Patrick O'Grady Date: Wed, 4 Aug 2021 01:10:37 -0700 Subject: [PATCH] core/rawdb: fix logs to print block number, not address (#23328) --- core/rawdb/accessors_indexes.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/rawdb/accessors_indexes.go b/core/rawdb/accessors_indexes.go index d6dab6808d..25a44354bf 100644 --- a/core/rawdb/accessors_indexes.go +++ b/core/rawdb/accessors_indexes.go @@ -106,7 +106,7 @@ func ReadTransaction(db ethdb.Reader, hash common.Hash) (*types.Transaction, com } body := ReadBody(db, blockHash, *blockNumber) if body == nil { - log.Error("Transaction referenced missing", "number", blockNumber, "hash", blockHash) + log.Error("Transaction referenced missing", "number", *blockNumber, "hash", blockHash) return nil, common.Hash{}, 0, 0 } for txIndex, tx := range body.Transactions { @@ -114,7 +114,7 @@ func ReadTransaction(db ethdb.Reader, hash common.Hash) (*types.Transaction, com return tx, blockHash, *blockNumber, uint64(txIndex) } } - log.Error("Transaction not found", "number", blockNumber, "hash", blockHash, "txhash", hash) + log.Error("Transaction not found", "number", *blockNumber, "hash", blockHash, "txhash", hash) return nil, common.Hash{}, 0, 0 } @@ -137,7 +137,7 @@ func ReadReceipt(db ethdb.Reader, hash common.Hash, config *params.ChainConfig) return receipt, blockHash, *blockNumber, uint64(receiptIndex) } } - log.Error("Receipt not found", "number", blockNumber, "hash", blockHash, "txhash", hash) + log.Error("Receipt not found", "number", *blockNumber, "hash", blockHash, "txhash", hash) return nil, common.Hash{}, 0, 0 }