How come select says there is data, but read returns zero?
Answer Posted / chaitanya
The data that causes select to return is the EOF because the other side has closed the connection. This causes read to return zero.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is a socket file?
Are sockets files?
Can multiple sockets use the same port?
How can I force a socket to send the data in its buffer?
Is socket a hardware or software?
What is a socket set used for?
What is sae socket?
What exactly is a socket?
Is there any advantage to handling the signal, rather than just ignoring it and checking for the EPIPE error? Are there any useful parameters passed to the signal catching function?
What is socket address with example?
Can multiple clients connect to same socket?
How do I use TCP_NODELAY?
How does a socket work?
Are unix sockets faster than tcp?
system choose one for me on the connect() call? Should I bind() a port number in my client program, or let the?