diff options
| author | Luke Dashjr <[email protected]> | 2015-06-24 03:36:22 +0000 |
|---|---|---|
| committer | Luke Dashjr <[email protected]> | 2015-07-03 08:29:16 +0000 |
| commit | 0c376340a4efa2842e9ffd1d93eca9895b4a9391 (patch) | |
| tree | c4859c16b45c2693fd52caf433bf8c8435fccc98 /src/init.cpp | |
| parent | Remove translation for -help-debug options (diff) | |
| download | discoin-0c376340a4efa2842e9ffd1d93eca9895b4a9391.tar.xz discoin-0c376340a4efa2842e9ffd1d93eca9895b4a9391.zip | |
acceptnonstdtxn option to skip (most) "non-standard transaction" checks, for testnet/regtest only
Diffstat (limited to 'src/init.cpp')
| -rw-r--r-- | src/init.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/init.cpp b/src/init.cpp index 4473cd9ec..4a658a5da 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -395,6 +395,8 @@ std::string HelpMessage(HelpMessageMode mode) strUsage += HelpMessageOpt("-testnet", _("Use the test network")); strUsage += HelpMessageGroup(_("Node relay options:")); + if (showDebug) + strUsage += HelpMessageOpt("-acceptnonstdtxn", strprintf("Relay and mine \"non-standard\" transactions (%sdefault: %u)", "testnet/regtest only; ", !Params(CBaseChainParams::TESTNET).RequireStandard())); strUsage += HelpMessageOpt("-datacarrier", strprintf(_("Relay and mine data carrier transactions (default: %u)"), 1)); strUsage += HelpMessageOpt("-datacarriersize", strprintf(_("Maximum size of data in data carrier transactions we relay and mine (default: %u)"), MAX_OP_RETURN_RELAY)); @@ -803,6 +805,10 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler) return InitError(strprintf(_("Invalid amount for -minrelaytxfee=<amount>: '%s'"), mapArgs["-minrelaytxfee"])); } + fRequireStandard = !GetBoolArg("-acceptnonstdtxn", !Params().RequireStandard()); + if (Params().RequireStandard() && !fRequireStandard) + return InitError(strprintf("acceptnonstdtxn is not currently supported for %s chain", chainparams.NetworkIDString())); + #ifdef ENABLE_WALLET if (mapArgs.count("-mintxfee")) { |