Luciano Moreira - igLnx wrote: > 2) I ve noted that select() cannot detect socket shutdown()/closing from > peer, always returning OK and leaving in FD the socket originally being > tested by select(). select() just indicates that the socket is "ready"; this could mean that data is available, or it could mean that the connection has been terminated. Connection termination is indicated by read(), recv() etc returning zero, or by write(), send() etc either raising SIGPIPE, or (if SIGPIPE is caught) failing with EPIPE (i.e. write() returns -1 and sets errno to EPIPE). -- Glynn Clements <glynn.clements@virgin.net> - : send the line "unsubscribe linux-net" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html