aboutsummaryrefslogtreecommitdiff
path: root/src/rpc/util.cpp
diff options
context:
space:
mode:
authorMarcoFalke <falke.marco@gmail.com>2019-03-04 13:13:21 -0500
committerMarcoFalke <falke.marco@gmail.com>2019-03-04 13:13:36 -0500
commit45f434f44d0b55d137eaebb8c0486f9cebabc869 (patch)
tree9ab40a819ccf523042a40be61476f04494ae59ec /src/rpc/util.cpp
parent57acfcb9fd051556fc1f68ba49f109512c0cc846 (diff)
parentf7efd87c8fb49f82e268a95e989909d453500e2b (diff)
Merge #15288: Remove wallet -> node global function calls
f7efd87c8f Change brace formatting (Russell Yanofsky) a1df1b48a8 Remove use of IsInitialBlockDownload in wallet code (Russell Yanofsky) 1106a6fde4 Remove use of uiInterface.LoadWallet in wallet code (Russell Yanofsky) 318f41fb2c circular-dependencies: Avoid treating some .h/.cpp files as a unit (Russell Yanofsky) d02b34c8a8 Remove use of AcceptToMemoryPool in wallet code (Russell Yanofsky) e2c8ba9f6e Remove uses of InitMessage/Warning/Error in wallet code (Russell Yanofsky) c5e59a96a8 Remove uses of GetAdjustedTime in wallet code (Russell Yanofsky) 6d6bcc77c0 Remove use of g_connman / PushInventory in wallet code (Russell Yanofsky) 00dfb2a440 Remove uses of g_connman in wallet code (Russell Yanofsky) cc3836e8f9 Remove uses of fPruneMode in wallet code (Russell Yanofsky) cc02c796d3 Remove uses of fee globals in wallet code (Russell Yanofsky) 1fb0a4a04e Remove use of CalculateMemPoolAncestors in wallet code (Russell Yanofsky) cd32160af0 Remove use of GetTransactionAncestry in wallet code (Russell Yanofsky) 291276f7f4 Remove use of GetCountWithDescendants in wallet code (Russell Yanofsky) bdc6628683 Remove use of IsRBFOptIn in wallet code (Russell Yanofsky) 80f52a2267 Remove uses of CheckFinalTx in wallet code (Russell Yanofsky) Pull request description: This change removes wallet calls to node functions that access global chain and mempool state. This is the next step in the larger #10973 refactoring change, which removes all other accesses to node global variables from wallet code. Doing this is useful to provide a better defined interface between the wallet and node, and necessary to allow wallet and node code to run in separate processes in #10102. Tree-SHA512: 40dbaf1f59fb22b32e70b054b30ba5638d638aa3240fa30e0f721d53c721cd6138a7ab4d423a24d7d2fda0b956e68d44c733abc2c9259c3d6c9fd6d4be89aa23
Diffstat (limited to 'src/rpc/util.cpp')
-rw-r--r--src/rpc/util.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/rpc/util.cpp b/src/rpc/util.cpp
index 40ac133186..10979b43b0 100644
--- a/src/rpc/util.cpp
+++ b/src/rpc/util.cpp
@@ -4,11 +4,9 @@
#include <key_io.h>
#include <keystore.h>
-#include <policy/fees.h>
#include <rpc/util.h>
#include <tinyformat.h>
#include <util/strencodings.h>
-#include <validation.h>
InitInterfaces* g_rpc_interfaces = nullptr;
@@ -130,10 +128,9 @@ UniValue DescribeAddress(const CTxDestination& dest)
return boost::apply_visitor(DescribeAddressVisitor(), dest);
}
-unsigned int ParseConfirmTarget(const UniValue& value)
+unsigned int ParseConfirmTarget(const UniValue& value, unsigned int max_target)
{
int target = value.get_int();
- unsigned int max_target = ::feeEstimator.HighestTargetTracked(FeeEstimateHorizon::LONG_HALFLIFE);
if (target < 1 || (unsigned int)target > max_target) {
throw JSONRPCError(RPC_INVALID_PARAMETER, strprintf("Invalid conf_target, must be between %u - %u", 1, max_target));
}