summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2014-12-20 22:25:08 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2014-12-20 22:25:08 +0000
commitdb7f4d2c1ef70334af4cb8c1980f47d8a9f69249 (patch)
tree4d878ef25e634be9b9ae2b870905a548603ecc50 /configure
parent0d82edd9f8bebb396a9154d4e1003340dbf6b967 (diff)
downloadskalibs-db7f4d2c1ef70334af4cb8c1980f47d8a9f69249.tar.xz
Found the BSD unixmessage bug. recvmsg(..., MSG_WAITALL) blocks
until buffer full or socket shutdown on BSD, *even if the socket is nonblocking*. So I added an "okwaitall" sysdeps, and won't set MSG_WAITALL on retarded systems.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure8
1 files changed, 7 insertions, 1 deletions
diff --git a/configure b/configure
index cc1bdda..ba4439a 100755
--- a/configure
+++ b/configure
@@ -133,7 +133,12 @@ choose () {
fi
if $r ; then
case "$1" in
- *r*) ./try$2 >/dev/null 2>&1 || r=false ;;
+ *r*) ./try$2 >/dev/null 2>&1 ; r=$?
+ case "$r" in
+ 111) echo " ... test crashed, aborting." ; exit 111 ;;
+ 0) r=true ;;
+ *) r=false ;;
+ esac
esac
fi
rm -f try$2.o try$2
@@ -437,6 +442,7 @@ EOF
choose cl getpeerucred GETPEERUCRED 'getpeerucred()'
choose cl ipv6 IPV6 'IPv6 support' $socket_lib
choose clr malloc0 MALLOC0 'non-NULL malloc(0)'
+ choose clr okwaitall OKWAITALL 'a usable MSG_WAITALL flag'
choose cl openat OPENAT 'openat()'
choose cl linkat LINKAT 'linkat()'
choose clr pipe2 PIPE2 'pipe2()'