]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
With statvfs, f_bsize means something different. The fundamental block
authorwessels <>
Fri, 5 Jan 2001 02:11:49 +0000 (02:11 +0000)
committerwessels <>
Fri, 5 Jan 2001 02:11:49 +0000 (02:11 +0000)
size element is f_frsize.

src/store_dir.cc

index e791e61b5aa4f34dc323f07ea122db1ef83e9a90..129742552ec9ded2105aa14ed5c3385f02746d12 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: store_dir.cc,v 1.119 2001/01/04 07:32:08 wessels Exp $
+ * $Id: store_dir.cc,v 1.120 2001/01/04 19:11:49 wessels Exp $
  *
  * DEBUG: section 47    Store Directory Routines
  * AUTHOR: Duane Wessels
@@ -468,16 +468,17 @@ storeDirGetBlkSize(const char *path, int *blksize)
 #if HAVE_STATVFS
     struct statvfs sfs;
     if (statvfs(path, &sfs)) {
-       debug(0, 0) ("%s: %s\n", path, xstrerror());
+       debug(50, 1) ("%s: %s\n", path, xstrerror());
        return 1;
     }
+    *blksize = (int) sfs.f_frsize;
 #else
     struct statfs sfs;
     if (statfs(path, &sfs)) {
-       debug(0, 0) ("%s: %s\n", path, xstrerror());
+       debug(50, 1) ("%s: %s\n", path, xstrerror());
        return 1;
     }
-#endif
     *blksize = (int) sfs.f_bsize;
+#endif
     return 0;
 }