mirror of
https://github.com/ElementsProject/lightning.git
synced 2024-11-19 18:11:28 +01:00
lightningd/hsm: shutdown when master conn is freed.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
3509f10e30
commit
3c5a70910a
@ -83,6 +83,8 @@ static struct client *new_client(struct daemon_conn *master,
|
||||
c->master = master;
|
||||
daemon_conn_init(c, &c->dc, fd, handle);
|
||||
|
||||
/* Free the connection if we exit everything. */
|
||||
tal_steal(master, c->dc.conn);
|
||||
/* Free client when connection freed. */
|
||||
tal_steal(c->dc.conn, c);
|
||||
return c;
|
||||
|
Loading…
Reference in New Issue
Block a user