aboutsummaryrefslogtreecommitdiff
path: root/src/rpcwallet.cpp
diff options
context:
space:
mode:
authorHan Lin Yap <codler@gmail.com>2013-08-06 13:52:38 +0200
committerHan Lin Yap <codler@gmail.com>2013-08-07 10:14:33 +0200
commit15117692399a301e4a6f328016ef7e3cfe64d513 (patch)
tree0ad3b8c621088f47c12729e5a3e93b63098b4039 /src/rpcwallet.cpp
parent7b22c8e8ca745a66bbc3867f1bdbc19acf05a67f (diff)
Use existing RPC_INVALID_PARAMETER constant
Diffstat (limited to 'src/rpcwallet.cpp')
-rw-r--r--src/rpcwallet.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/rpcwallet.cpp b/src/rpcwallet.cpp
index 5388bd4d84..c4f14b4921 100644
--- a/src/rpcwallet.cpp
+++ b/src/rpcwallet.cpp
@@ -1492,18 +1492,18 @@ Value lockunspent(const Array& params, bool fHelp)
BOOST_FOREACH(Value& output, outputs)
{
if (output.type() != obj_type)
- throw JSONRPCError(-8, "Invalid parameter, expected object");
+ throw JSONRPCError(RPC_INVALID_PARAMETER, "Invalid parameter, expected object");
const Object& o = output.get_obj();
RPCTypeCheck(o, map_list_of("txid", str_type)("vout", int_type));
string txid = find_value(o, "txid").get_str();
if (!IsHex(txid))
- throw JSONRPCError(-8, "Invalid parameter, expected hex txid");
+ throw JSONRPCError(RPC_INVALID_PARAMETER, "Invalid parameter, expected hex txid");
int nOutput = find_value(o, "vout").get_int();
if (nOutput < 0)
- throw JSONRPCError(-8, "Invalid parameter, vout must be positive");
+ throw JSONRPCError(RPC_INVALID_PARAMETER, "Invalid parameter, vout must be positive");
COutPoint outpt(uint256(txid), nOutput);