Re: Expected result when racing listen(2) on two sockets bound to the same address

2018-05-23 Thread Kirill Tkhai
Hi, On 23.05.2018 14:15, Alexander Kurtz wrote: > [Please keep me CC'ed; I'm not subscribed to the list] > > Hi! > > The program shown below (also available at [0]) does the following: > > * Create two sockets > * Enable SO_REUSEADDR on both > * Bind both sockets to [::1]:12345 > * Spawn tw

Expected result when racing listen(2) on two sockets bound to the same address

2018-05-23 Thread Alexander Kurtz
[Please keep me CC'ed; I'm not subscribed to the list] Hi! The program shown below (also available at [0]) does the following: * Create two sockets * Enable SO_REUSEADDR on both * Bind both sockets to [::1]:12345 * Spawn two threads which both call listen(2) on one socket each * Check that