mirror of https://git.musl-libc.org/git/musl
Browse Source
at the same time, make struct statfs match the traditional definition and make it more useful, especially the fsid_t stuff.rs-1.0
7 changed files with 88 additions and 70 deletions
@ -1,16 +1,7 @@ |
|||
struct statvfs { |
|||
unsigned long f_type; |
|||
unsigned long f_bsize; |
|||
fsblkcnt_t f_blocks; |
|||
fsblkcnt_t f_bfree; |
|||
fsblkcnt_t f_bavail; |
|||
fsfilcnt_t f_files; |
|||
fsfilcnt_t f_ffree; |
|||
unsigned long f_fsid; |
|||
unsigned long __unused; |
|||
unsigned long f_namemax; |
|||
unsigned long f_frsize; |
|||
fsfilcnt_t f_favail; |
|||
unsigned long f_flag; |
|||
unsigned long __reserved[2]; |
|||
struct statfs { |
|||
unsigned long f_type, f_bsize; |
|||
fsblkcnt_t f_blocks, f_bfree, f_bavail; |
|||
fsfilcnt_t f_files, f_ffree; |
|||
fsid_t f_fsid; |
|||
unsigned long f_namelen, f_frsize, f_flags, f_spare[4]; |
|||
}; |
|||
|
|||
@ -1,16 +1,7 @@ |
|||
struct statvfs { |
|||
unsigned long f_type; |
|||
unsigned long f_bsize; |
|||
fsblkcnt_t f_blocks; |
|||
fsblkcnt_t f_bfree; |
|||
fsblkcnt_t f_bavail; |
|||
fsfilcnt_t f_files; |
|||
fsfilcnt_t f_ffree; |
|||
unsigned long f_fsid; |
|||
unsigned long __unused; |
|||
unsigned long f_namemax; |
|||
unsigned long f_frsize; |
|||
fsfilcnt_t f_favail; |
|||
unsigned long f_flag; |
|||
unsigned long __reserved[2]; |
|||
struct statfs { |
|||
unsigned long f_type, f_bsize; |
|||
fsblkcnt_t f_blocks, f_bfree, f_bavail; |
|||
fsfilcnt_t f_files, f_ffree; |
|||
fsid_t f_fsid; |
|||
unsigned long f_namelen, f_frsize, f_flags, f_spare[4]; |
|||
}; |
|||
|
|||
@ -1,15 +1,7 @@ |
|||
struct statvfs { |
|||
unsigned long f_type; |
|||
unsigned long f_bsize; |
|||
fsblkcnt_t f_blocks; |
|||
fsblkcnt_t f_bfree; |
|||
fsblkcnt_t f_bavail; |
|||
fsfilcnt_t f_files; |
|||
fsfilcnt_t f_ffree; |
|||
unsigned long f_fsid; |
|||
unsigned long f_namemax; |
|||
unsigned long f_frsize; |
|||
fsfilcnt_t f_favail; |
|||
unsigned long f_flag; |
|||
unsigned long __reserved[3]; |
|||
struct statfs { |
|||
unsigned long f_type, f_bsize; |
|||
fsblkcnt_t f_blocks, f_bfree, f_bavail; |
|||
fsfilcnt_t f_files, f_ffree; |
|||
fsid_t f_fsid; |
|||
unsigned long f_namelen, f_frsize, f_flags, f_spare[4]; |
|||
}; |
|||
|
|||
@ -1,17 +0,0 @@ |
|||
#include <sys/statvfs.h> |
|||
#include "syscall.h" |
|||
#include "libc.h" |
|||
|
|||
int fstatvfs(int fd, struct statvfs *buf) |
|||
{ |
|||
#ifdef SYS_fstatfs64 |
|||
return syscall(SYS_fstatfs64, fd, sizeof *buf, buf); |
|||
#else |
|||
return syscall(SYS_fstatfs, fd, buf); |
|||
#endif |
|||
} |
|||
|
|||
weak_alias(fstatvfs, fstatfs); |
|||
|
|||
LFS64(fstatvfs); |
|||
LFS64(fstatfs); |
|||
Loading…
Reference in new issue