/*
- * $Id: store_dir.cc,v 1.128 2001/03/13 19:11:25 wessels Exp $
+ * $Id: store_dir.cc,v 1.129 2001/03/28 14:45:40 wessels Exp $
*
* DEBUG: section 47 Store Directory Routines
* AUTHOR: Duane Wessels
struct statvfs sfs;
if (statvfs(path, &sfs)) {
debug(50, 1) ("%s: %s\n", path, xstrerror());
+ *blksize = 2048;
return 1;
}
*blksize = (int) sfs.f_frsize;
struct statfs sfs;
if (statfs(path, &sfs)) {
debug(50, 1) ("%s: %s\n", path, xstrerror());
+ *blksize = 2048;
return 1;
}
*blksize = (int) sfs.f_bsize;
#endif
+ /*
+ * Sanity check; make sure we have a meaningful value.
+ */
+ if (*blksize > 512)
+ *blksize = 2048;
return 0;
}