aboutsummaryrefslogtreecommitdiff
path: root/src/rpc
diff options
context:
space:
mode:
authorWladimir J. van der Laan <[email protected]>2016-03-21 18:02:47 +0100
committerWladimir J. van der Laan <[email protected]>2016-03-21 18:02:58 +0100
commitc946a15075ba5a2da74a08bb5575391541196475 (patch)
tree66efd73dc16ec1cd8a7a5515dfe1cde9fd49284d /src/rpc
parentMerge #7692: Remove p2p alert system (diff)
parentmodify release-notes.md and bips.md (diff)
downloaddiscoin-c946a15075ba5a2da74a08bb5575391541196475.tar.xz
discoin-c946a15075ba5a2da74a08bb5575391541196475.zip
Merge #7542: Implement "feefilter" P2P message
0371797 modify release-notes.md and bips.md (Alex Morcos) b536a6f Add p2p test for feefilter (Alex Morcos) 5fa66e4 Create SingleNodeConnCB class for RPC tests (Alex Morcos) 9e072a6 Implement "feefilter" P2P message. (Alex Morcos)
Diffstat (limited to 'src/rpc')
-rw-r--r--src/rpc/rawtransaction.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/rpc/rawtransaction.cpp b/src/rpc/rawtransaction.cpp
index de89fdeb0..c72339313 100644
--- a/src/rpc/rawtransaction.cpp
+++ b/src/rpc/rawtransaction.cpp
@@ -818,11 +818,12 @@ UniValue sendrawtransaction(const UniValue& params, bool fHelp)
const CCoins* existingCoins = view.AccessCoins(hashTx);
bool fHaveMempool = mempool.exists(hashTx);
bool fHaveChain = existingCoins && existingCoins->nHeight < 1000000000;
+ CFeeRate txFeeRate = CFeeRate(0);
if (!fHaveMempool && !fHaveChain) {
// push to local node and sync with wallets
CValidationState state;
bool fMissingInputs;
- if (!AcceptToMemoryPool(mempool, state, tx, false, &fMissingInputs, false, nMaxRawTxFee)) {
+ if (!AcceptToMemoryPool(mempool, state, tx, false, &fMissingInputs, &txFeeRate, false, nMaxRawTxFee)) {
if (state.IsInvalid()) {
throw JSONRPCError(RPC_TRANSACTION_REJECTED, strprintf("%i: %s", state.GetRejectCode(), state.GetRejectReason()));
} else {
@@ -835,7 +836,7 @@ UniValue sendrawtransaction(const UniValue& params, bool fHelp)
} else if (fHaveChain) {
throw JSONRPCError(RPC_TRANSACTION_ALREADY_IN_CHAIN, "transaction already in block chain");
}
- RelayTransaction(tx);
+ RelayTransaction(tx, txFeeRate);
return hashTx.GetHex();
}