[−][src]Function udp_sas::recv_sas
pub fn recv_sas(
socket: RawFd,
buf: &mut [u8]
) -> Result<(usize, Option<SocketAddr>, Option<IpAddr>)>
Receive a datagram (low-level function)
Parameters
buf
: buffer for storing the payload
Returns a tuple containing:
- the size of the payload
- the source socket address (peer)
- the destination ip address (local)
Note: the source (peer) and destination (local) addresses may not be present in the result if the underlying socket does not provide them.