On Mon, May 9, 2011 at 7:22 AM, James Carlson <carls...@workingcode.com> wrote: > Nico Williams wrote: >> Re-reading the documentation posted here, I agree, the socket must >> continue to shutdown gracefully. (An application might then reset the >> linger option so that the socket is reset... it might be nice to have >> a simple API by which to request "linger upto N seconds, then give up >> and reset the connection".) > > I think that already exists. To get that behavior: > > - set l_onoff to 1 and l_linger to 0 > - do shutdown(fd,1) to send FIN > - set a timer for N seconds > - read(fd) to wait for EOF or timer > - close(fd) or just exit
Ah, good to know! Thanks. _______________________________________________ networking-discuss mailing list networking-discuss@opensolaris.org