Function connect_unspec

Source
pub fn connect_unspec<Fd: AsFd>(sockfd: Fd) -> Result<()>
Available on crate feature net only.
Expand description

connect(sockfd, {.sa_family = AF_UNSPEC}, sizeof(struct sockaddr))— Dissolve the socket’s association.

On UDP sockets, BSD platforms report Errno::AFNOSUPPORT or Errno::INVAL even if the disconnect was successful.

§References