bug-gnulib
[Top][All Lists]
Advanced

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

Re: bug#6331: [sshfs] df reports wrong disk space usage on solaris


From: Bruno Haible
Subject: Re: bug#6331: [sshfs] df reports wrong disk space usage on solaris
Date: Sun, 4 Jul 2010 23:49:46 +0200
User-agent: KMail/1.9.9

Jim Meyering wrote:
> > OK to commit?
> 
> Yes, that looks fine.

Actually MacOS X and OpenBSD now also support the POSIX API (statvfs function).
I've adjusted the comments as below and pushed it.


--- m4/fsusage.m4  2010-07-04 23:44:29.000000000 +0200
+++ m4/fsusage.m4    2010-07-04 23:41:11.000000000 +0200
@@ -44,8 +44,8 @@
 # systems.  That system is reported to work fine with STAT_STATFS4 which
 # is what it gets when this test fails.
 if test $ac_fsusage_space = no; then
-  # glibc/{Hurd,kFreeBSD}, FreeBSD, NetBSD, AIX, HP-UX, IRIX, Solaris, Cygwin,
-  # Interix, BeOS.
+  # glibc/{Hurd,kFreeBSD}, MacOS X >= 10.4, FreeBSD >= 5.0, NetBSD >= 3.0,
+  # OpenBSD >= 4.4, AIX, HP-UX, IRIX, Solaris, Cygwin, Interix, BeOS.
   AC_CACHE_CHECK([for statvfs function (SVR4)], [fu_cv_sys_stat_statvfs],
                  [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <sys/types.h>
 #if defined __GLIBC__ && defined __linux__
@@ -98,9 +98,9 @@
 fi
 
 if test $ac_fsusage_space = no; then
-  # glibc/Linux, MacOS X, OpenBSD.
-  # (glibc/{Hurd,kFreeBSD}, FreeBSD, NetBSD, AIX, HP-UX, OSF/1, Cygwin already
-  # handled above.)
+  # glibc/Linux, MacOS X < 10.4, FreeBSD < 5.0, NetBSD < 3.0, OpenBSD < 4.4.
+  # (glibc/{Hurd,kFreeBSD}, MacOS X >= 10.4, FreeBSD >= 5.0, NetBSD >= 3.0,
+  # OpenBSD >= 4.4, AIX, HP-UX, OSF/1, Cygwin already handled above.)
   # (On IRIX you need to include <sys/statfs.h>, not only <sys/mount.h> and
   # <sys/vfs.h>.)
   # (On Solaris, statfs has 4 arguments.)
--- lib/fsusage.c  2010-07-04 23:44:29.000000000 +0200
+++ lib/fsusage.c    2010-07-04 23:41:28.000000000 +0200
@@ -166,7 +166,8 @@
   fsp->fsu_blocksize = PROPAGATE_ALL_ONES (fsd.f_fsize);
 
 #elif defined STAT_STATFS2_BSIZE        /* glibc/Linux, 4.3BSD, SunOS 4, \
-                                           MacOS X, OpenBSD */
+                                           MacOS X < 10.4, FreeBSD < 5.0, \
+                                           NetBSD < 3.0, OpenBSD < 4.4 */
 
   struct statfs fsd;
 



reply via email to

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