Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
identify: Fix memory leak of unused
pending_opens
(#273)
The identify protocol implementation leaked SubstreamIds and PeerIds via the `pending_opens` hashMap. Objects were only inserted in the `pending_opens`, however they were never removed. The only possible purpose of `pending_opens` is to double-check the events coming from the service layer: `TransportEvent::SubstreamOpened`. However this is not needed, as illustrated by the current implementation. Part of endeavors to fix memory leaks: paritytech/polkadot-sdk#6149 ### Testing Done - custom patched litep2p to dump the internal state of identify protocol running in kusama cc @paritytech/networking Signed-off-by: Alexandru Vasile <[email protected]>
- Loading branch information