Function vector::net::set_receive_buffer_size

source ·
pub fn set_receive_buffer_size<'s, S>(socket: &'s S, size: usize) -> Result<()>
where SockRef<'s>: From<&'s S>,
Expand description

Sets the receive buffer size for a socket.

This is the equivalent of setting the SO_RCVBUF socket setting directly.

§Errors

If there is an error setting the receive buffer size on the given socket, or if the value given as the socket is not a valid socket, an error variant will be returned explaining the underlying I/O error.