From d490e27304d7754d7a069afe6b9fb180b108999c Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 16 Oct 2006 21:32:36 +0000 Subject: r19346: AF_LOCAL isn't defined on all platforms. (This used to be commit e9bd6f28d830ed7ead1412a26b532538cd1450e0) --- source4/torture/subunit.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'source4/torture') diff --git a/source4/torture/subunit.c b/source4/torture/subunit.c index 72e39101e2..3cad622d6f 100644 --- a/source4/torture/subunit.c +++ b/source4/torture/subunit.c @@ -72,7 +72,11 @@ static pid_t piped_child(char* const command[], int *f_in) pid_t pid; int sock[2]; - if (socketpair(PF_UNIX, SOCK_STREAM, AF_LOCAL, sock) == -1) { +#ifdef HAVE_SOCKETPAIR + if (socketpair(AF_UNIX, SOCK_STREAM, 0, sock) == -1) { +#else + if (pipe(sock) == -1) { +#endif DEBUG(0, ("socketpair: %s", strerror(errno))); return -1; } -- cgit