Chapter 57, Unix Domain Sockets

  • ssize_t recvfrom(int sockfd, void *restrict buf, size_t len, int flags, struct sockaddr *restrict src_addr, socklen_t *restrict addrlen);
  • ssize_t sendto(int sockfd, const void *buf, size_t len, int flags, const struct sockaddr *dest_addr, socklen_t addrlen);
  • For this setup, you can have multiple clients communicating at the same time.
  • The previous example was a datagram example.
  • Let's build a stream example.