How to transfer file descriptors with UNIX domain sockets?
Guy Harris
guy at auspex.auspex.com
Tue Jul 3 04:00:54 AEST 1990
>I'm sure that it *can* be done - my question is what was it in Oliver
>Laumann's code that informed the kernel that what was in the message was a
>file descriptor?
It was
msg.msg_accrights = (caddr_t)&fd;
msg.msg_accrightslen = sizeof (fd);
I.e., the "access rights" in a message sent down a UNIX-domain socket
are, by definition, file descriptors....
More information about the Comp.unix.questions
mailing list