From: octo Date: Sun, 29 Jan 2006 22:04:58 +0000 (+0000) Subject: Changed `df.c' to prefer `statvfs' over `statfs', since apparently the latter is... X-Git-Tag: collectd-3.7.0~9 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=41347b17cff92567c6087b98087f23ad38b1ecb5;p=collectd.git Changed `df.c' to prefer `statvfs' over `statfs', since apparently the latter is deprecated.. --- diff --git a/src/df.c b/src/df.c index 69dc2994..8cc9f2eb 100644 --- a/src/df.c +++ b/src/df.c @@ -33,13 +33,12 @@ # define DF_HAVE_READ 0 #endif -#if HAVE_STATFS -#define STATANYFS statfs -#define BLOCKSIZE(s) (s).f_bsize - -#elif HAVE_STATVFS -#define STATANYFS statvfs -#define BLOCKSIZE(s) ((s).f_frsize ? (s).f_frsize : (s).f_bsize) +#if HAVE_STATVFS +# define STATANYFS statvfs +# define BLOCKSIZE(s) ((s).f_frsize ? (s).f_frsize : (s).f_bsize) +#elif HAVE_STATFS +# define STATANYFS statfs +# define BLOCKSIZE(s) (s).f_bsize #endif static char *filename_template = "df-%s.rrd";