bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] Robustify configure check for /dev/fd


From: Greg Schafer
Subject: [PATCH] Robustify configure check for /dev/fd
Date: Mon, 14 Aug 2006 12:51:09 +1000
User-agent: Pan/0.14.2 (This is not a psychotic episode. It's a cleansing moment of clarity.)

Hi

This issue was reported earlier but with apparently no response:

  http://lists.gnu.org/archive/html/bug-bash/2006-05/msg00018.html

When su'd to a non-root user under Linux the configure check fails:

  checking whether /dev/fd is available... absent

Here is a suggested patch as per the following analysis:

  http://linuxfromscratch.org/pipermail/lfs-dev/2006-August/057860.html


diff -Naur bash-3.1.orig/aclocal.m4 bash-3.1/aclocal.m4
--- bash-3.1.orig/aclocal.m4    2005-05-09 19:23:14.000000000 +0000
+++ bash-3.1/aclocal.m4 2006-08-14 02:45:30.000000000 +0000
@@ -1542,7 +1542,7 @@
 AC_CACHE_VAL(bash_cv_dev_fd,
 [if test -d /dev/fd  && test -r /dev/fd/0 < /dev/null; then
 # check for systems like FreeBSD 5 that only provide /dev/fd/[012]
-   exec 3<&0
+   exec 3</dev/null
    if test -r /dev/fd/3; then
      bash_cv_dev_fd=standard
    else


Thanks
Greg





reply via email to

[Prev in Thread] Current Thread [Next in Thread]