From fa539d3281850976c4a465bbceeffe01d3959f79 Mon Sep 17 00:00:00 2001 From: niftynei Date: Tue, 15 Dec 2020 12:28:41 -0600 Subject: [PATCH] df-tests: make memleak happy by cleaning up `psbt` We don't need it anymore. Normally it gets cleaned up by `cmd` but we're done with it here. --- lightningd/dual_open_control.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lightningd/dual_open_control.c b/lightningd/dual_open_control.c index cf10a08a2..24e0f7d60 100644 --- a/lightningd/dual_open_control.c +++ b/lightningd/dual_open_control.c @@ -1611,6 +1611,9 @@ json_openchannel_signed(struct command *cmd, return command_fail(cmd, FUNDING_PSBT_INVALID, "Failed adding sigs"); } + + /* Make memleak happy, (otherwise cleaned up with `cmd`) */ + tal_free(psbt); tal_wally_end(tal_steal(channel, channel->psbt)); wallet_channel_save(cmd->ld->wallet, channel);