blockchain: Remove unnecessary tx hash
This commit is contained in:
parent
ba3fe57507
commit
95fea6420c
1 changed files with 1 additions and 2 deletions
|
@ -877,7 +877,6 @@ func CheckTransactionInputs(tx *btcutil.Tx, txHeight int32, utxoView *UtxoViewpo
|
||||||
return 0, nil
|
return 0, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
txHash := tx.Hash()
|
|
||||||
var totalSatoshiIn int64
|
var totalSatoshiIn int64
|
||||||
for txInIndex, txIn := range tx.MsgTx().TxIn {
|
for txInIndex, txIn := range tx.MsgTx().TxIn {
|
||||||
// Ensure the referenced input transaction is available.
|
// Ensure the referenced input transaction is available.
|
||||||
|
@ -954,7 +953,7 @@ func CheckTransactionInputs(tx *btcutil.Tx, txHeight int32, utxoView *UtxoViewpo
|
||||||
if totalSatoshiIn < totalSatoshiOut {
|
if totalSatoshiIn < totalSatoshiOut {
|
||||||
str := fmt.Sprintf("total value of all transaction inputs for "+
|
str := fmt.Sprintf("total value of all transaction inputs for "+
|
||||||
"transaction %v is %v which is less than the amount "+
|
"transaction %v is %v which is less than the amount "+
|
||||||
"spent of %v", txHash, totalSatoshiIn, totalSatoshiOut)
|
"spent of %v", tx.Hash(), totalSatoshiIn, totalSatoshiOut)
|
||||||
return 0, ruleError(ErrSpendTooHigh, str)
|
return 0, ruleError(ErrSpendTooHigh, str)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue