diff options
author | Joey Hess <joey@kitenet.net> | 2012-03-22 17:30:35 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2012-03-22 17:32:47 -0400 |
commit | d7d2fefbf2e670f9ba160769620b3e268712dab8 (patch) | |
tree | d249059101e2a0dd0eb3d3e58f5362ff10dc4a6d /Utility | |
parent | e38a839a80ae70eba13b6fd0e7ee08be8a62c513 (diff) |
break out kfreebsd
Now tested on linux and freebsd (amd64).
Diffstat (limited to 'Utility')
-rw-r--r-- | Utility/diskfree.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/Utility/diskfree.c b/Utility/diskfree.c index 9ac31a752..b8d8aa3b3 100644 --- a/Utility/diskfree.c +++ b/Utility/diskfree.c @@ -13,11 +13,17 @@ # define STATSTRUCT statfs # define STATCALL statfs64 #else -#if defined (__FreeBSD__) || defined (__FreeBSD_kernel__) +#if defined (__FreeBSD__) # include <sys/param.h> # include <sys/mount.h> # define STATSTRUCT statfs -# define STATCALL statfs +# define STATCALL statfs /* statfs64 not yet tested on a real FreeBSD machine */ +#else +#if defined (__FreeBSD_kernel__) /* Debian kFreeBSD */ +# include <sys/param.h> +# include <sys/mount.h> +# define STATSTRUCT statfs +# define STATCALL statfs64 #else #if defined (__linux__) # include <sys/statvfs.h> @@ -29,8 +35,10 @@ #endif #endif #endif +#endif #include <errno.h> +#include <stdio.h> /* Checks the amount of disk that is available to regular (non-root) users. * (If there's an error, or this is not supported, |