* BUG: SO_LINGER + shutdown() does not block?
@ 2001-02-11 18:38 Chris Evans
2001-02-11 20:21 ` kuznet
0 siblings, 1 reply; 6+ messages in thread
From: Chris Evans @ 2001-02-11 18:38 UTC (permalink / raw)
To: linux-kernel; +Cc: davem
Hi,
>From socket(7):
SO_LINGER
...
When enabled, a close(2) or shutdown(2) will not
return until all queued messages for the socket
have been successfully sent or the linger timeout
has been reached.
I'm not seeing shutdown(2) block on a TCP socket. This is Linux kernel
2.2.16 (RH7.0). Is this a kernel bug, a documentation bug, or does it all
work fine and it's a Chris bug?
Cheers
Chris
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: BUG: SO_LINGER + shutdown() does not block?
2001-02-11 18:38 BUG: SO_LINGER + shutdown() does not block? Chris Evans
@ 2001-02-11 20:21 ` kuznet
2001-02-11 20:41 ` Chris Evans
0 siblings, 1 reply; 6+ messages in thread
From: kuznet @ 2001-02-11 20:21 UTC (permalink / raw)
To: Chris Evans; +Cc: linux-kernel
Hello!
> I'm not seeing shutdown(2) block on a TCP socket. This is Linux kernel
> 2.2.16 (RH7.0). Is this a kernel bug, a documentation bug,
Man page is wrong.
What's about kernel... Hmm, actually, it is worth to test genuine bsd.
Such feature could be useful.
Alexey
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: BUG: SO_LINGER + shutdown() does not block?
2001-02-11 20:21 ` kuznet
@ 2001-02-11 20:41 ` Chris Evans
2001-02-11 20:51 ` Andi Kleen
0 siblings, 1 reply; 6+ messages in thread
From: Chris Evans @ 2001-02-11 20:41 UTC (permalink / raw)
To: kuznet; +Cc: linux-kernel, ak
[cc: Andi]
On Sun, 11 Feb 2001 kuznet@ms2.inr.ac.ru wrote:
> Hello!
>
> > I'm not seeing shutdown(2) block on a TCP socket. This is Linux kernel
> > 2.2.16 (RH7.0). Is this a kernel bug, a documentation bug,
>
> Man page is wrong.
Yes, man socket(7) seems to be wrong.
I don't have access to a genuine BSD at the moment, but from man pages:
- HP/UX specifically states that SO_LINGER has no effect on shutdown()
- Solaris SO_LINGER only mentions that close() is affected.
- Likewise FreeBSD
Cheers
Chris
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: BUG: SO_LINGER + shutdown() does not block?
2001-02-11 20:41 ` Chris Evans
@ 2001-02-11 20:51 ` Andi Kleen
2001-02-11 21:05 ` Chris Evans
0 siblings, 1 reply; 6+ messages in thread
From: Andi Kleen @ 2001-02-11 20:51 UTC (permalink / raw)
To: Chris Evans; +Cc: kuznet, linux-kernel, ak
On Sun, Feb 11, 2001 at 08:41:04PM +0000, Chris Evans wrote:
>
> [cc: Andi]
Missing context..
>
> On Sun, 11 Feb 2001 kuznet@ms2.inr.ac.ru wrote:
>
> > Hello!
> >
> > > I'm not seeing shutdown(2) block on a TCP socket. This is Linux kernel
> > > 2.2.16 (RH7.0). Is this a kernel bug, a documentation bug,
> >
> > Man page is wrong.
>
> Yes, man socket(7) seems to be wrong.
What do you exactly think is wrong?
-Andi
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: BUG: SO_LINGER + shutdown() does not block?
2001-02-11 20:51 ` Andi Kleen
@ 2001-02-11 21:05 ` Chris Evans
2001-02-11 21:08 ` Andi Kleen
0 siblings, 1 reply; 6+ messages in thread
From: Chris Evans @ 2001-02-11 21:05 UTC (permalink / raw)
To: Andi Kleen; +Cc: kuznet, linux-kernel
On Sun, 11 Feb 2001, Andi Kleen wrote:
> On Sun, Feb 11, 2001 at 08:41:04PM +0000, Chris Evans wrote:
> >
> > [cc: Andi]
>
> Missing context..
[...]
> What do you exactly think is wrong?
man socket(7) says that setting SO_LINGER on a socket will make shutdown()
and close() block. That's incorrect; only close() blocks.
Sorry for the missing context.
Cheers
Chris
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: BUG: SO_LINGER + shutdown() does not block?
2001-02-11 21:05 ` Chris Evans
@ 2001-02-11 21:08 ` Andi Kleen
0 siblings, 0 replies; 6+ messages in thread
From: Andi Kleen @ 2001-02-11 21:08 UTC (permalink / raw)
To: Chris Evans; +Cc: Andi Kleen, kuznet, linux-kernel
On Sun, Feb 11, 2001 at 09:05:07PM +0000, Chris Evans wrote:
>
> On Sun, 11 Feb 2001, Andi Kleen wrote:
>
> > On Sun, Feb 11, 2001 at 08:41:04PM +0000, Chris Evans wrote:
> > >
> > > [cc: Andi]
> >
> > Missing context..
>
> [...]
>
> > What do you exactly think is wrong?
>
> man socket(7) says that setting SO_LINGER on a socket will make shutdown()
> and close() block. That's incorrect; only close() blocks.
Ok, fixed. Thanks.
-Andi
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2001-02-11 21:08 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-02-11 18:38 BUG: SO_LINGER + shutdown() does not block? Chris Evans
2001-02-11 20:21 ` kuznet
2001-02-11 20:41 ` Chris Evans
2001-02-11 20:51 ` Andi Kleen
2001-02-11 21:05 ` Chris Evans
2001-02-11 21:08 ` Andi Kleen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®