|
|
To receive data on an unconnected datagram socket,
use recvfrom:
recvfrom (s, buf, buflen, flags, &from, &fromlen);
Again, fromlen initially contains the size of the from buffer, and is modified on return to indicate the actual size of the address from which the datagram was received.