mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-03-01 09:40:19 +01:00
hsmd: Fix a memory leak in status.c
This commit is contained in:
parent
c737fa6b91
commit
c5f4c9cefb
1 changed files with 7 additions and 0 deletions
|
@ -61,12 +61,19 @@ void status_setup_sync(int fd)
|
|||
#endif
|
||||
}
|
||||
|
||||
static void destroy_daemon_conn(struct daemon_conn *dc UNUSED)
|
||||
{
|
||||
status_conn = NULL;
|
||||
}
|
||||
|
||||
void status_setup_async(struct daemon_conn *master)
|
||||
{
|
||||
assert(status_fd == -1);
|
||||
assert(!status_conn);
|
||||
status_conn = master;
|
||||
|
||||
tal_add_destructor(master, destroy_daemon_conn);
|
||||
|
||||
setup_logging_sighandler();
|
||||
#if DEVELOPER
|
||||
logging_io = (getenv("LIGHTNINGD_DEV_LOG_IO") != NULL);
|
||||
|
|
Loading…
Add table
Reference in a new issue