From: Dean M. B. <mik...@gm...> - 2010-04-10 05:20:28
|
On Sat, Apr 10, 2010 at 1:49 AM, Nelson, Erik - 2 <eri...@ba...> wrote: > > http://msdn.microsoft.com/en-us/library/ms740621%28VS.85%29.aspx > > looks like maybe there should be no SO_REUSADDR (or maybe there should be a SO_EXCLUSIVEADDRUSE) as SO_REUSADDR causes indeterminate behavior > If the system is POSIX compliant, this should not be an issue because SO_REUSEADDR applies to whether the listening application can re-use the socket in the TIME_WAIT state (that which has been closed already). This is important for efficiency reasons, although can definitely be dangerous in systems where the networking stack doesn't clean up properly. If this is a problem only in Windows then we should have a special compiler flag that turns it off. http://www.unixguide.net/network/socketfaq/4.5.shtml -- Dean Michael Berris deanberris.com |