From 87616b7ffc44d18d218edb32bc168f7e6ceae887 Mon Sep 17 00:00:00 2001 From: niftynei Date: Thu, 27 Oct 2022 11:22:08 -0500 Subject: [PATCH] mkfunding: add missing common_setup Was crashing on allocating wally memory, b/c was missing the wally_init that's wrapped up in common_setup Assisted-By: @TKChattoraj --- devtools/mkfunding.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/devtools/mkfunding.c b/devtools/mkfunding.c index 878212de0..fa817da42 100644 --- a/devtools/mkfunding.c +++ b/devtools/mkfunding.c @@ -12,6 +12,7 @@ #include #include #include +#include #include #include #include @@ -86,7 +87,7 @@ int main(int argc, char *argv[]) struct bitcoin_txid txid; u8 **witnesses; - setup_locale(); + common_setup(argv[0]); chainparams = chainparams_for_network("bitcoin"); secp256k1_ctx = secp256k1_context_create(SECP256K1_CONTEXT_VERIFY | @@ -168,6 +169,7 @@ int main(int argc, char *argv[]) type_to_string(NULL, struct bitcoin_txid, &txid)); printf("tx: %s\n", tal_hex(NULL, linearize_tx(NULL, tx))); + common_shutdown(); return 0; }