From 832492eee2e73816e7ec7e9476e82b343e0838b5 Mon Sep 17 00:00:00 2001 From: Jarkko Hietaniemi Date: Mon, 2 Jul 2001 16:28:56 +0000 Subject: The fcntl locking test may hang if NFS locking messed up; break out with alarm(10). p4raw-id: //depot/perl@11093 --- Configure | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) (limited to 'Configure') diff --git a/Configure b/Configure index f91462ed7a..19f05b82d2 100755 --- a/Configure +++ b/Configure @@ -20,7 +20,7 @@ # $Id: Head.U,v 3.0.1.9 1997/02/28 15:02:09 ram Exp $ # -# Generated on Fri Jun 29 17:44:53 EET DST 2001 [metaconfig 3.0 PL70] +# Generated on Mon Jul 2 19:35:08 EET DST 2001 [metaconfig 3.0 PL70] # (with additional metaconfig patches by perlbug@perl.org) cat >c1$$ <try.c <<'EOCP' +$cat >try.c < #include #include +#include +#ifdef SIGALRM +$signal_t blech(x) int x; { exit(3); } +#endif +EOCP +$cat >try.c <<'EOCP' int main() { #if defined(F_SETLK) && defined(F_SETLKW) struct flock flock; @@ -9872,6 +9878,10 @@ int main() { flock.l_type = F_RDLCK; flock.l_whence = SEEK_SET; flock.l_start = flock.l_len = 0; +#ifdef SIGALRM + signal(SIGALRM, blech); + alarm(10); +#endif retval = fcntl(fd, F_SETLK, &flock); close(fd); (retval < 0 ? exit(2) : exit(0)); @@ -9891,6 +9901,18 @@ case "$d_fcntl" in else echo "Nope, it didn't work." val="$undef" + case "$?" in + 3) $cat >&4 <