aboutsummaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
authorRussell Yanofsky <russ@yanofsky.org>2020-04-02 08:35:10 -0400
committerRussell Yanofsky <russ@yanofsky.org>2020-04-02 08:35:10 -0400
commit01a3392b1b778fa4fcf568013326d6ea1de4fb3b (patch)
tree4a498b5cc8d1121e9ab7276fc335b778043cd8a2 /src/test
parent0660119ac372c2863d14060ac1bc9bc243771f94 (diff)
Drop bitcoin-wallet dependency on libevent
Don't require urlDecode function in wallet code since urlDecode implementation currently uses libevent. Just call urlDecode indirectly though URL_DECODE function pointer constant if available. In bitcoind and bitcoin-qt, URL_DECODE is implemented and used to interpret RPC wallet requests. In bitcoin-wallet, URL_DECODE is null to avoid depending on libevent.
Diffstat (limited to 'src/test')
-rw-r--r--src/test/util/setup_common.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/test/util/setup_common.cpp b/src/test/util/setup_common.cpp
index d684b97787..b7f5dcfe43 100644
--- a/src/test/util/setup_common.cpp
+++ b/src/test/util/setup_common.cpp
@@ -27,12 +27,14 @@
#include <util/string.h>
#include <util/time.h>
#include <util/translation.h>
+#include <util/url.h>
#include <validation.h>
#include <validationinterface.h>
#include <functional>
const std::function<std::string(const char*)> G_TRANSLATION_FUN = nullptr;
+UrlDecodeFn* const URL_DECODE = nullptr;
FastRandomContext g_insecure_rand_ctx;
/** Random context to get unique temp data dirs. Separate from g_insecure_rand_ctx, which can be seeded from a const env var */