mirror of
https://github.com/aljazceru/lightning.git
synced 2026-01-04 23:04:35 +01:00
gossipd: peer->local->peer_out queue should have lifetime of peer->local.
The current code attaches it to peer, which is a slight leak. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
committed by
Christian Decker
parent
e098578731
commit
a7e6cdb418
@@ -353,7 +353,7 @@ new_local_peer_state(struct peer *peer, const struct crypto_state *cs)
|
||||
lps->pcs.cs = *cs;
|
||||
lps->return_to_master = false;
|
||||
lps->num_pings_outstanding = 0;
|
||||
msg_queue_init(&lps->peer_out, peer);
|
||||
msg_queue_init(&lps->peer_out, lps);
|
||||
|
||||
return lps;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user