diff options
| author | Wladimir J. van der Laan <[email protected]> | 2014-07-18 23:23:41 +0200 |
|---|---|---|
| committer | Wladimir J. van der Laan <[email protected]> | 2014-07-18 23:29:50 +0200 |
| commit | ff1fe669d41814a4e0406243d1c081725006a735 (patch) | |
| tree | 7da8f1b73c21f01ecb9ada221bf1e0ba703de892 /src/main.cpp | |
| parent | qt: Make error message for failed export a little friendlier (diff) | |
| parent | Introduce option to disable relay/mining of bare multisig scripts in TX outputs (diff) | |
| download | discoin-ff1fe669d41814a4e0406243d1c081725006a735.tar.xz discoin-ff1fe669d41814a4e0406243d1c081725006a735.zip | |
Merge pull request #3939
3da434a Introduce option to disable relay/mining of bare multisig scripts in TX outputs (Jeff Garzik)
Diffstat (limited to 'src/main.cpp')
| -rw-r--r-- | src/main.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/main.cpp b/src/main.cpp index 766f0970f..dd9e76378 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -48,6 +48,7 @@ bool fImporting = false; bool fReindex = false; bool fBenchmark = false; bool fTxIndex = false; +bool fIsBareMultisigStd = true; unsigned int nCoinCacheSize = 5000; /** Fees smaller than this (in satoshi) are considered zero fee (for relaying and mining) */ @@ -604,9 +605,13 @@ bool IsStandardTx(const CTransaction& tx, string& reason) reason = "scriptpubkey"; return false; } + if (whichType == TX_NULL_DATA) nDataOut++; - else if (txout.IsDust(::minRelayTxFee)) { + else if ((whichType == TX_MULTISIG) && (!fIsBareMultisigStd)) { + reason = "bare-multisig"; + return false; + } else if (txout.IsDust(::minRelayTxFee)) { reason = "dust"; return false; } |