How can I read ICMP errors from connected UDP sockets?
Answer / chaitanya
If the target machine discards the message because there is no process reading on the requested port number, it sends an ICMP message to your machine which will cause the next system call on the socket to return ECONNREFUSED. Since delivery of ICMP messages is not guarenteed you may not recieve this notification on the first transaction.
| Is This Answer Correct ? | 0 Yes | 0 No |
What is the difference between read() and recv()?
What exactly does SO_LINGER do?
What is Mac, and how is it different from PC? Which one is better for professional users, and why
1 Answers Evolving Systems, IBM,
How do I properly close a socket?
How can I bind() to a port number < 1024?
What is a socket address?
What pieces of information make up a socket?
What is a deep well socket?
over the socket? Is there a way to have a dynamic buffer? What does one do when one does not know how much information is coming?
Why does the sockets buffer fill up sooner than expected?
How do unix sockets work?
What are Sockets?