CValidationState framework

This commit is contained in:
Pieter Wuille
2013-01-27 00:14:11 +01:00
committed by Pieter Wuille
parent 2835080e16
commit ef3988ca36
8 changed files with 226 additions and 213 deletions

View File

@@ -546,8 +546,9 @@ Value sendrawtransaction(const Array& params, bool fHelp)
fHave = view.GetCoins(hashTx, existingCoins);
if (!fHave) {
// push to local node
if (!tx.AcceptToMemoryPool(true, false))
throw JSONRPCError(RPC_DESERIALIZATION_ERROR, "TX rejected");
CValidationState state;
if (!tx.AcceptToMemoryPool(state, true, false))
throw JSONRPCError(RPC_DESERIALIZATION_ERROR, "TX rejected"); // TODO: report validation state
}
}
if (fHave) {