diff options
author | Rob Landley <rob@landley.net> | 2021-02-22 19:48:49 -0600 |
---|---|---|
committer | Rob Landley <rob@landley.net> | 2021-02-22 19:48:49 -0600 |
commit | 1f9e37e36117c51a17f017143f1b68787d913979 (patch) | |
tree | 5841c85b9019c99ea2464afea19866cae79262d8 /lib | |
parent | e2ad5c6c155ef63833f6d3774b607c314fbe8987 (diff) | |
download | toybox-1f9e37e36117c51a17f017143f1b68787d913979.tar.gz |
Remove ifdefs from stat.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/portability.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/portability.h b/lib/portability.h index b3646473..54f97afd 100644 --- a/lib/portability.h +++ b/lib/portability.h @@ -215,6 +215,11 @@ int posix_fallocate(int, off_t, off_t); // macOS keeps newlocale(3) in the non-POSIX <xlocale.h> rather than <locale.h>. #include <xlocale.h> +static inline long statfs_bsize(struct statfs *sf) { return sf->f_iosize; } +static inline long statfs_frsize(struct statfs *sf) { return sf->f_bsize; } +#else +static inline long statfs_bsize(struct statfs *sf) { return sf->f_bsize; } +static inline long statfs_frsize(struct statfs *sf) { return sf->f_frsize; } #endif |