Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
proton-c-0.18.0
-
None
Description
It is possible that closing a listener while an incoming connection is about to trigger an epoll event on the listener can result in accessing free'd memory.
The solution is to force an event event to fire via a shutdown() call on the socket and delay deletion until the callback completes. This strategy is already in use by the pconnection cleanup logic, which can be used as a template.