Skip to content

Commit 55fbcb8

Browse files
committed
splice script: Fix rare memleak in plugin
Fix leaking of the `abort_pkg` if our peer does not support splicing.
1 parent 48271d5 commit 55fbcb8

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

plugins/spender/splice.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ static struct command_result *do_fail(struct command *cmd,
187187
"splice_error(psbt:%p, splice_cmd:%p, str: %s)",
188188
splice_cmd->psbt, splice_cmd, str ?: "");
189189

190-
abort_pkg = tal(cmd->plugin, struct abort_pkg);
190+
abort_pkg = tal(cmd, struct abort_pkg);
191191
abort_pkg->splice_cmd = tal_steal(abort_pkg, splice_cmd);
192192
abort_pkg->str = tal_strdup(abort_pkg, str);
193193
abort_pkg->code = code;

0 commit comments

Comments
 (0)