More specific RPC error reporting.

This commit is contained in:
Arthur Britto
2013-01-16 15:03:36 -08:00
parent 0d7f8cbe13
commit 503e9a7ddc
4 changed files with 5 additions and 3 deletions

View File

@@ -2553,10 +2553,10 @@ Json::Value RPCHandler::doInternal(Json::Value jvRequest)
return RPCInternalHandler::runHandler(jvRequest["internal_command"].asString(), jvRequest["params"]);
}
Json::Value RPCHandler::doCommand(Json::Value& jvRequest, int iRole)
Json::Value RPCHandler::doCommand(const Json::Value& jvRequest, int iRole)
{
if (!jvRequest.isMember("command"))
return rpcError(rpcINVALID_PARAMS);
return rpcError(rpcCOMMAND_MISSING);
std::string strCommand = jvRequest["command"].asString();