Skip to content

Commit

Permalink
Remove reference to X__val (pkg#142)
Browse files Browse the repository at this point in the history
Fixes golang/go#17298

This field is not present in all versions of the syscall package.
  • Loading branch information
davecheney authored and techjacker committed Dec 5, 2016
1 parent 1b823a1 commit f8c996e
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions server_statvfs_linux.go
Expand Up @@ -15,9 +15,8 @@ func statvfsFromStatfst(stat *syscall.Statfs_t) (*StatVFS, error) {
Bavail: stat.Bavail,
Files: stat.Files,
Ffree: stat.Ffree,
Favail: stat.Ffree, // not sure how to calculate Favail
Fsid: uint64(uint64(stat.Fsid.X__val[1])<<32 | uint64(stat.Fsid.X__val[0])), // endianness?
Flag: uint64(stat.Flags), // assuming POSIX?
Favail: stat.Ffree, // not sure how to calculate Favail
Flag: uint64(stat.Flags), // assuming POSIX?
Namemax: uint64(stat.Namelen),
}, nil
}

0 comments on commit f8c996e

Please sign in to comment.