aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGavin Andresen <gavinandresen@gmail.com>2012-01-23 13:09:34 -0500
committerGavin Andresen <gavinandresen@gmail.com>2012-01-23 13:09:34 -0500
commitb8056dc5d0b10ca31998ef9bd6b4702f47374ae2 (patch)
tree3adc06609fa6743e184d9305f1094e3e530fdf72 /src
parent149f580c82922a3b79e4e7fd6ed85adcc0522d91 (diff)
parent575bdcde931c100288843a8f3540426490a78a60 (diff)
Merge branch 'bugfix_areinpstd' of https://github.com/luke-jr/bitcoin
Diffstat (limited to 'src')
-rw-r--r--src/main.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/main.cpp b/src/main.cpp
index e3b98b2e6e..e242fa640d 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -277,11 +277,8 @@ bool CTransaction::IsStandard() const
//
bool CTransaction::AreInputsStandard(const MapPrevTx& mapInputs) const
{
- if (fTestNet)
- return true; // Allow non-standard on testnet
-
if (IsCoinBase())
- return true; // Coinbases are allowed to have any input
+ return true; // Coinbases don't use vin normally
for (int i = 0; i < vin.size(); i++)
{
@@ -503,7 +500,7 @@ bool CTransaction::AcceptToMemoryPool(CTxDB& txdb, bool fCheckInputs, bool* pfMi
}
// Check for non-standard pay-to-script-hash in inputs
- if (!AreInputsStandard(mapInputs))
+ if (!AreInputsStandard(mapInputs) && !fTestNet)
return error("AcceptToMemoryPool() : nonstandard transaction input");
int64 nFees = GetValueIn(mapInputs)-GetValueOut();