This has the same semantics than SOCK_DGRAM but it also supports the
ability to notify the other end of end-of-file events. However, it may
not be widely implemented, hence the separate commit.
int pair[2];
/* Create socket pair */
- if (socketpair(AF_UNIX, SOCK_DGRAM, PF_UNSPEC, pair) < 0)
+ if (socketpair(AF_UNIX, SOCK_SEQPACKET, PF_UNSPEC, pair) < 0)
fatal("privsep", "unable to create socket pair for privilege separation");
priv_unprivileged_fd(pair[0]);