From 3e785f2bcc139dde84bd351628fcc098366e0d31 Mon Sep 17 00:00:00 2001 From: Gregory Sanders Date: Fri, 16 Nov 2018 13:02:30 -0500 Subject: [PATCH] combineblocksigs should check if signed blocks are active --- src/rpc/mining.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/rpc/mining.cpp b/src/rpc/mining.cpp index 10a4c81e86..ff6695bce6 100644 --- a/src/rpc/mining.cpp +++ b/src/rpc/mining.cpp @@ -1005,6 +1005,10 @@ UniValue combineblocksigs(const JSONRPCRequest& request) + HelpExampleCli("combineblocksigs", " [\"signature1\", \"signature2\", ...]") ); + if (!g_signed_blocks) { + throw JSONRPCError(RPC_MISC_ERROR, "Signed blocks are not active for this network."); + } + CBlock block; if (!DecodeHexBlk(block, request.params[0].get_str())) throw JSONRPCError(RPC_DESERIALIZATION_ERROR, "Block decode failed");