From: Manfred Spraul <manfred@colorfullife.com>
To: "Nick Palmer" <nick@sluggardy.net>
Cc: linux-kernel@vger.kernel.org
Subject: Re: select implementation not POSIX compliant?
Date: Wed, 11 Aug 2004 22:49:10 +0200 [thread overview]
Message-ID: <411A8646.1030205@colorfullife.com> (raw)
Nick wrote:
>Furthermore, a call to close and then select in the same thread
>blocks while the other thread is still in select, which has a very large
>surprise factor, since the code would work were it not for the other
>select.
>
>
>
Could you post the test case for this behavior: I assume your test app
is buggy: a select call that is executed after close returned must
return EBADF, everything else would be a bug.
Regarding your main point: The return result from select/poll is
undefined in Linux if you close a descriptor while another thread polls
or selects it.
This is consistent with the behavior of other Unices - for example HP UX
kills the process if you replace a descriptor that is being polled with
dup2.
--
Manfred
next reply other threads:[~2004-08-11 20:46 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-08-11 20:49 Manfred Spraul [this message]
2004-08-13 20:18 ` select implementation not POSIX compliant? Nick Palmer
2004-08-13 22:05 ` Alan Cox
-- strict thread matches above, loose matches on Subject: below --
2004-08-11 17:00 Nick Palmer
2004-08-11 19:40 ` Alex Riesen
2004-08-11 20:33 ` khandelw
2004-08-11 21:23 ` Alex Riesen
2004-08-13 20:13 ` Nick Palmer
2004-08-11 21:57 ` Steven Dake
2004-08-13 20:12 ` Nick Palmer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=411A8646.1030205@colorfullife.com \
--to=manfred@colorfullife.com \
--cc=linux-kernel@vger.kernel.org \
--cc=nick@sluggardy.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.