How to cleanup after Socket.bind on Linux?

Ali Çehreli acehreli at yahoo.com
Tue Aug 27 21:48:33 PDT 2013


On 08/27/2013 02:02 AM, Regan Heath wrote:

 > You could set the REUSE option on the socket prior to 'bind', this would
 > allow you to bind again while the previous socket was in cleanup.

That worked. I copied the following line from std/socket.d:

     listener.setOption(SocketOptionLevel.SOCKET,
                        SocketOption.REUSEADDR, true);

Ali



More information about the Digitalmars-d-learn mailing list