Brian Somers <[EMAIL PROTECTED]> wrote:
>
>Hmm, the last time i looked at this, I believe the whole thing was
>dealt with by not increasing the file descriptor reference count
>when it was put in the message header. If process A closed the
>descriptor before process B actually recvmsg()d it, it would be
>EBADF. The recvmsg() actually incremented the reference count.
But it has always been documented behaviour that the receiving process
gets a valid descriptor even if the sender closes it directly after
sendmsging it. If this was not the case then descriptor handoff would
require an "ok" reply from the receiving process before the sender
could close it, which is a pain.
Hmm, the only references for this I can think of are Stevens and the
red & black daemon books, but I'm sure I've read a good discussion of
it somewhere else.
Tony.
--
f.a.n.finch [EMAIL PROTECTED] [EMAIL PROTECTED]
"And remember my friend, future events such
as these will affect you in the future."
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-net" in the body of the message