]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
.
authorJim Meyering <jim@meyering.net>
Tue, 18 Mar 2003 17:48:02 +0000 (17:48 +0000)
committerJim Meyering <jim@meyering.net>
Tue, 18 Mar 2003 17:48:02 +0000 (17:48 +0000)
aclocal.m4
lib/ChangeLog

index 4246db4e6b7c5cf98cc505df1842bbdcb89da003..0f56ab2b9d88a78f1442baf6fee55d9543117476 100644 (file)
@@ -4824,7 +4824,7 @@ AC_DEFUN([jm_FUNC_UNLINK_BUSY_TEXT],
   fi
 ])
 
-#serial 11
+#serial 12
 
 dnl From Jim Meyering.
 dnl
@@ -4893,6 +4893,23 @@ yes
   fi
 fi
 
+if test -z "$ac_list_mounted_fs"; then
+  # AIX.
+  AC_MSG_CHECKING([for mntctl function and struct vmount])
+  AC_CACHE_VAL(fu_cv_sys_mounted_vmount,
+  [AC_TRY_CPP([#include <fshelp.h>],
+    fu_cv_sys_mounted_vmount=yes,
+    fu_cv_sys_mounted_vmount=no)])
+  AC_MSG_RESULT($fu_cv_sys_mounted_vmount)
+  if test $fu_cv_sys_mounted_vmount = yes; then
+    ac_list_mounted_fs=found
+    AC_DEFINE(MOUNTED_VMOUNT, 1,
+       [Define if there is a function named mntctl that can be used to read
+   the list of mounted filesystems, and there is a system header file
+   that declares `struct vmount.'  (AIX)])
+  fi
+fi
+
 if test $ac_cv_func_getmntent = yes; then
 
   # This system has the getmntent function.
@@ -4979,23 +4996,6 @@ if test -z "$ac_list_mounted_fs"; then
   fi
 fi
 
-if test -z "$ac_list_mounted_fs"; then
-  # AIX.
-  AC_MSG_CHECKING([for mntctl function and struct vmount])
-  AC_CACHE_VAL(fu_cv_sys_mounted_vmount,
-  [AC_TRY_CPP([#include <fshelp.h>],
-    fu_cv_sys_mounted_vmount=yes,
-    fu_cv_sys_mounted_vmount=no)])
-  AC_MSG_RESULT($fu_cv_sys_mounted_vmount)
-  if test $fu_cv_sys_mounted_vmount = yes; then
-    ac_list_mounted_fs=found
-    AC_DEFINE(MOUNTED_VMOUNT, 1,
-       [Define if there is a function named mntctl that can be used to read
-   the list of mounted filesystems, and there is a system header file
-   that declares `struct vmount.'  (AIX)])
-  fi
-fi
-
 if test -z "$ac_list_mounted_fs"; then
   # SVR3
   AC_MSG_CHECKING([for FIXME existence of three headers])
index e30f862fbd3f167c540e8b0d6b64246c26af21fe..0f152475b412ba02665cb631a5b6e1397d6018be 100644 (file)
@@ -1,5 +1,12 @@
 2003-03-18  Jim Meyering  <jim@meyering.net>
 
+       * mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
+       error from mntctl.
+       Use mntctl's return value to drive the entry-processing loop, since
+       we can't rely on the value of the vmt_length member in the last
+       entry.  On some systems doing so could result in an infinite loop.
+       Based in part on a patch from Mike Jetzer.
+
        * exclude.c (excluded_filename): Define and use typedef to
        avoid type mismatch in conditional expression.