about summary refs log tree commit diff
path: root/sysdeps
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>1999-05-07 16:58:39 +0000
committerUlrich Drepper <drepper@redhat.com>1999-05-07 16:58:39 +0000
commit42d666a5cbbc41ee099aa8ae31bbe531c32c08cf (patch)
tree7b51171f7de29a477be502b7e611d995ed2b2853 /sysdeps
parent31c46cf53db2849e7318fc0ee3418ef909c69466 (diff)
downloadglibc-42d666a5cbbc41ee099aa8ae31bbe531c32c08cf.tar.gz
glibc-42d666a5cbbc41ee099aa8ae31bbe531c32c08cf.tar.xz
glibc-42d666a5cbbc41ee099aa8ae31bbe531c32c08cf.zip
Update.
	* sysdeps/unix/sysv/linux/fstatvfs.c (fstatvfs): Set f_frsize to
	f_bsize to help some broken programs.
Diffstat (limited to 'sysdeps')
-rw-r--r--sysdeps/unix/sysv/linux/fstatvfs.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/sysdeps/unix/sysv/linux/fstatvfs.c b/sysdeps/unix/sysv/linux/fstatvfs.c
index 3192c20d0b..ea142860d9 100644
--- a/sysdeps/unix/sysv/linux/fstatvfs.c
+++ b/sysdeps/unix/sysv/linux/fstatvfs.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 1999 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
 
@@ -39,6 +39,8 @@ fstatvfs (int fd, struct statvfs *buf)
 
   /* Now fill in the fields we have information for.  */
   buf->f_bsize = fsbuf.f_bsize;
+  /* Linux does not support f_frsize, so set it to the full block size.  */
+  buf->f_frsize = fsbuf.f_bsize;
   buf->f_blocks = fsbuf.f_blocks;
   buf->f_bfree = fsbuf.f_bfree;
   buf->f_bavail = fsbuf.f_bavail;
@@ -48,11 +50,7 @@ fstatvfs (int fd, struct statvfs *buf)
   buf->f_namemax = fsbuf.f_namelen;
   memset (buf->f_spare, '\0', 6 * sizeof (int));
 
-  /* What remains to do is to fill the fields f_frsize, f_favail,
-     and f_flag.  */
-
-  /* Linux does not support f_frsize, so set it to zero.  */
-  buf->f_frsize = 0;
+  /* What remains to do is to fill the fields f_favail and f_flag.  */
 
   /* XXX I have no idea how to compute f_favail.  Any idea???  */
   buf->f_favail = buf->f_ffree;