>Yes, this is not very clear either. In the meantime you can play safe by > relying only on the inheritance of STDIN_FILENO and STDOUT_FILENO. > >> And unfortunatly socketpair need fd process inherance, so sad :( > > "so sad"? Just copy the 8 line of code relating to dup2() from > tests/test-nonblocking-pipe-main.c, and you're done. > Did you test if dup2 work for socket ?
According to http://www.suacommunity.com/dictionary/dup-entry.php and http://blog.csdn.net/linlu11/archive/2008/06/06/2518571.aspx it will need more work. Any thought ? Bastien