Skip to content

Commit

Permalink
Merge pull request #10306 from filecoin-project/steb/error-cleanup
Browse files Browse the repository at this point in the history
fix: eth: cleanup error cases
  • Loading branch information
arajasek authored Feb 17, 2023
2 parents e17d4f1 + bad41c2 commit e3e78f1
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion node/impl/full/eth.go
Original file line number Diff line number Diff line change
Expand Up @@ -926,7 +926,7 @@ func (a *EthModule) EthEstimateGas(ctx context.Context, tx ethtypes.EthCall) (et

expectedGas, err := ethGasSearch(ctx, a.Chain, a.Stmgr, a.Mpool, gassedMsg, ts)
if err != nil {
log.Errorw("expected gas", "err", err)
return 0, xerrors.Errorf("gas search failed: %w", err)
}

return ethtypes.EthUint64(expectedGas), nil
Expand Down Expand Up @@ -2188,11 +2188,13 @@ func (m *EthTxHashManager) ProcessSignedMessage(ctx context.Context, msg *types.
ethTx, err := newEthTxFromSignedMessage(ctx, msg, m.StateAPI)
if err != nil {
log.Errorf("error converting filecoin message to eth tx: %s", err)
return
}

err = m.TransactionHashLookup.UpsertHash(ethTx.Hash, msg.Cid())
if err != nil {
log.Errorf("error inserting tx mapping to db: %s", err)
return
}
}

Expand Down

0 comments on commit e3e78f1

Please sign in to comment.