]> gitweb.factorcode.org Git - factor.git/blob - basis/unix/statfs/openbsd/openbsd.factor
4e65e74c2c085f37ced2478c446b8124aa67e9c5
[factor.git] / basis / unix / statfs / openbsd / openbsd.factor
1 ! Copyright (C) 2008 Doug Coleman.
2 ! See http://factorcode.org/license.txt for BSD license.
3 USING: alien.c-types alien.syntax unix.types classes.struct 
4 unix.stat ;
5 IN: unix.statfs.openbsd
6
7 CONSTANT: MFSNAMELEN 16
8 CONSTANT: MNAMELEN 90
9
10 STRUCT: statfs
11     { f_flags u_int32_t }
12     { f_bsize u_int32_t }
13     { f_iosize u_int32_t }
14     { f_blocks u_int64_t }
15     { f_bfree u_int64_t }
16     { f_bavail int64_t }
17     { f_files u_int64_t }
18     { f_ffree u_int64_t }
19     { f_favail int64_t }
20     { f_syncwrites u_int64_t }
21     { f_syncreads u_int64_t }
22     { f_asyncwrites u_int64_t }
23     { f_asyncreads u_int64_t }
24     { f_fsid fsid_t }
25     { f_namemax u_int32_t }
26     { f_owner uid_t }
27     { f_ctime u_int32_t }
28     { f_spare u_int32_t[3] }
29     { f_fstypename { char MFSNAMELEN } }
30     { f_mntonname { char MNAMELEN } }
31     { f_mntfromname { char MNAMELEN } }
32     { mount_info char[160] } ;
33
34 FUNCTION: int statfs ( char* path, statfs* buf ) ;