mirror of
https://github.com/aljazceru/lightning.git
synced 2026-01-08 16:44:22 +01:00
bitcoind: fix clone_bitcoin_tx() when tx is take().
We need to actually steal it onto requested context in this case! Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -597,7 +597,7 @@ struct bitcoin_tx *clone_bitcoin_tx(const tal_t *ctx,
|
||||
struct bitcoin_tx *newtx;
|
||||
|
||||
if (taken(tx))
|
||||
return cast_const(struct bitcoin_tx *, tx);
|
||||
return cast_const(struct bitcoin_tx *, tal_steal(ctx, tx));
|
||||
|
||||
newtx = tal(ctx, struct bitcoin_tx);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user