mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-19 07:04:22 +01:00
libplugin: mark the cmd notleak() whenever command_still_pending() called.
This is what we do in lightningd, which makes memleak much more forgiving: you can hang temporaries off cmd without getting reports of leaks (also when send_outreq called). We remove all the notleak() calls in plugins which worked around this! And avoid multiple notleak labels, since both send_outreq() and command_still_pending() can be called multiple times. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -1202,10 +1202,6 @@ static struct command_result *json_pay(struct command *cmd,
|
||||
}
|
||||
payment_mod_exemptfee_get_data(p)->amount
|
||||
= exemptfee ? *exemptfee : AMOUNT_MSAT(5000);
|
||||
|
||||
/* We free unneeded params now to keep memleak happy. */
|
||||
tal_free(maxfee_pct_millionths);
|
||||
tal_free(exemptfee);
|
||||
}
|
||||
|
||||
shadow_route = payment_mod_shadowroute_get_data(p);
|
||||
|
||||
Reference in New Issue
Block a user