FreeBSD/tools/regression/sockets/sblock/sblock.c
/*
 * Process that will perform a blocking recv on a UNIX domain socket.  This
 * should return one byte of data.
 */
Process that will perform a blocking recv on a UNIX domain socket.  This
should return one byte of data.
Process that will perform a blocking recv on a UNIX domain socket . This should return one byte of data .
static void
blocking_recver(int fd)
{
	ssize_t len;
	char ch;
	len = recv(fd, &ch, sizeof(ch), 0);
	if (len < 0)
		err(-1, "FAIL: blocking_recver: recv");
	if (len == 0)
		errx(-1, "FAIL: blocking_recver: recv: eof");
	if (len != 1)
		errx(-1, "FAIL: blocking_recver: recv: %zd bytes", len);
	if (interrupted)
		errx(-1, "FAIL: blocking_recver: interrupted wrong pid");
}
static void blocking_recver ( int fd ) { ssize_t len ; char ch ; len = recv ( fd , & ch , sizeof ( ch ) , 0 ) ; if ( len < 0 ) err ( -1 , " " ) ; if ( len == 0 ) errx ( -1 , " " ) ; if ( len != 1 ) errx ( -1 , " " , len ) ; if ( interrupted ) errx ( -1 , " " ) ; }
Process that will perform a blocking recv on a UNIX domain socket.
Process that will perform a blocking recv on a UNIX domain socket .