diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2017-06-24 15:15:06 +0200 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2017-06-24 15:15:18 +0200 |
commit | 00350bd6db91545c9d307733448af9432ee151c7 (patch) | |
tree | 460def707af2742f0badcdcc1b80ce38135d64bb /src/rpc | |
parent | 2772dc9f2199b1dad8ff1f5fa13143c0a898b1ac (diff) | |
parent | 0ef7de953f5eeb27651690871c18c4dc1ee4f83b (diff) |
Merge #10191: [trivial] Rename unused RPC arguments 'dummy'
0ef7de9 [RPCs] Remove submitblock parameters argument help text (John Newbery)
Tree-SHA512: f39ad4bb3006e3d722fa51ae2ab4a48726e740993d6bed5737b355d1e0a99cf475ca9519f97adf8cde1b7187b14a24d5951ce4f34624d01d9ef84b49124c2894
Diffstat (limited to 'src/rpc')
-rw-r--r-- | src/rpc/mining.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/rpc/mining.cpp b/src/rpc/mining.cpp index 3b212dc0e4..8c682592c5 100644 --- a/src/rpc/mining.cpp +++ b/src/rpc/mining.cpp @@ -722,19 +722,16 @@ protected: UniValue submitblock(const JSONRPCRequest& request) { + // We allow 2 arguments for compliance with BIP22. Argument 2 is ignored. if (request.fHelp || request.params.size() < 1 || request.params.size() > 2) { throw std::runtime_error( - "submitblock \"hexdata\" ( \"jsonparametersobject\" )\n" + "submitblock \"hexdata\" ( \"dummy\" )\n" "\nAttempts to submit new block to network.\n" - "The 'jsonparametersobject' parameter is currently ignored.\n" "See https://en.bitcoin.it/wiki/BIP_0022 for full specification.\n" "\nArguments\n" "1. \"hexdata\" (string, required) the hex-encoded block data to submit\n" - "2. \"parameters\" (string, optional) object of optional parameters\n" - " {\n" - " \"workid\" : \"id\" (string, optional) if the server provided a workid, it MUST be included with submissions\n" - " }\n" + "2. \"dummy\" (optional) dummy value, for compatibility with BIP22. This value is ignored.\n" "\nResult:\n" "\nExamples:\n" + HelpExampleCli("submitblock", "\"mydata\"") @@ -963,7 +960,7 @@ static const CRPCCommand commands[] = { "mining", "getmininginfo", &getmininginfo, true, {} }, { "mining", "prioritisetransaction", &prioritisetransaction, true, {"txid","dummy","fee_delta"} }, { "mining", "getblocktemplate", &getblocktemplate, true, {"template_request"} }, - { "mining", "submitblock", &submitblock, true, {"hexdata","parameters"} }, + { "mining", "submitblock", &submitblock, true, {"hexdata","dummy"} }, { "generating", "generate", &generate, true, {"nblocks","maxtries"} }, { "generating", "generatetoaddress", &generatetoaddress, true, {"nblocks","address","maxtries"} }, |