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 connected and unconnected sockets?
Why do we need sockets?
Explain the TIME_WAIT state.
of the socket? Does doing a connect() call affect the receive behaviour?
How can I be sure that UDP messages are received in order?
How do I use TCP_NODELAY?
How do unix sockets work?
How come I get address already in use from bind()?
What is sae socket?
What is active unix domain sockets?
What exactly does SO_KEEPALIVE do?
How many sockets can a cpu have?