From e576962cb3c391ad5f97f258b594bef61b0f436c Mon Sep 17 00:00:00 2001 From: Dave Collins Date: Mon, 30 Sep 2013 16:43:10 -0500 Subject: [PATCH] Export the CheckTransactionSanity function. --- validate.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/validate.go b/validate.go index 941897fe..824f1260 100644 --- a/validate.go +++ b/validate.go @@ -173,9 +173,9 @@ func calcBlockSubsidy(height int64) int64 { return baseSubsidy >> uint(height/subsidyHalvingInterval) } -// checkTransactionSanity performs some preliminary checks on a transaction to +// CheckTransactionSanity performs some preliminary checks on a transaction to // ensure it is sane. These checks are context free. -func checkTransactionSanity(tx *btcwire.MsgTx) error { +func CheckTransactionSanity(tx *btcwire.MsgTx) error { // A transaction must have at least one input. if len(tx.TxIn) == 0 { return RuleError("transaction has no inputs") @@ -437,7 +437,7 @@ func (b *BlockChain) checkBlockSanity(block *btcutil.Block) error { // Do some preliminary checks on each transaction to ensure they are // sane before continuing. for _, tx := range transactions { - err := checkTransactionSanity(tx) + err := CheckTransactionSanity(tx) if err != nil { return err }