@@ -4,7 +4,7 @@ use crate::fs::{file_type::FileType, permissions::FilePermissions};
4
4
5
5
pub ( crate ) struct FileAttr {
6
6
#[ cfg( target_os = "linux" ) ]
7
- pub ( crate ) stat : stat64 ,
7
+ pub ( crate ) stat : libc :: stat64 ,
8
8
#[ cfg( target_os = "macos" ) ]
9
9
pub ( crate ) stat : libc:: stat ,
10
10
#[ cfg( target_os = "linux" ) ]
@@ -33,16 +33,16 @@ impl FileAttr {
33
33
/// Extra fields that are available in `statx` struct.
34
34
#[ cfg( target_os = "linux" ) ]
35
35
pub ( crate ) struct StatxExtraFields {
36
- stx_mask : u32 ,
37
- stx_btime : libc:: statx_timestamp ,
36
+ pub ( crate ) stx_mask : u32 ,
37
+ pub ( crate ) stx_btime : libc:: statx_timestamp ,
38
38
}
39
39
40
40
/// Convert a `statx` struct to not platform-specific `FileAttr`.
41
41
/// Current implementation is only for Linux.
42
42
#[ cfg( target_os = "linux" ) ]
43
- impl From < statx > for FileAttr {
44
- fn from ( buf : statx ) -> Self {
45
- let mut stat: stat64 = unsafe { std:: mem:: zeroed ( ) } ;
43
+ impl From < libc :: statx > for FileAttr {
44
+ fn from ( buf : libc :: statx ) -> Self {
45
+ let mut stat: libc :: stat64 = unsafe { std:: mem:: zeroed ( ) } ;
46
46
47
47
stat. st_dev = libc:: makedev ( buf. stx_dev_major , buf. stx_dev_minor ) as _ ;
48
48
stat. st_ino = buf. stx_ino as libc:: ino64_t ;
0 commit comments