Subject: Re: [Bug 106241] New: shutdown(3)/close(3) behaviour is incorrect for sockets in accept(3)

From: Alan Burlison <[email-masked]>
Date: Tue, 27 Oct 2015 12:27:33 +0000

On 27/10/2015 12:01, Eric Dumazet wrote:

> Are non multi threaded applications considered well written ?
>
> listener = socket(...);
> bind(listener, ...);
> listen(fd, 10000);
> Loop 1 10
>    if (fork() == 0)
>      do_accept(listener)
>
> Now if a child does a close(listener), or is killed, you propose that it
> does an implicit shutdown() and all other children no longer can
> accept() ?

No, of course not. I made it quite clear I was talking about MT programs.

> Surely you did not gave all details on how it is really working.

In the case of Hadoop, it works the way I describe.

-- 
Alan Burlison
--