Skip to content
Snippets Groups Projects
  • Craig Tiller's avatar
    a99157f4
    Fix server shutdown · a99157f4
    Craig Tiller authored
    A previous fix to make close() occur later can cause socket reuse by servers to fail as previous sockets are left asynchronously open.
    
    This change:
    - adds a callback to TCP server shutdown to signal that the server is completely shutdown
    - wait for that callback before destroying listeners in the server (and before destroying the server)
    - handles fallout
    a99157f4
    History
    Fix server shutdown
    Craig Tiller authored
    A previous fix to make close() occur later can cause socket reuse by servers to fail as previous sockets are left asynchronously open.
    
    This change:
    - adds a callback to TCP server shutdown to signal that the server is completely shutdown
    - wait for that callback before destroying listeners in the server (and before destroying the server)
    - handles fallout