Fix #125: Linux unix-stat returns wrong values
To simplify the implementation, we define our own C function to return the parts of the stat structure that we want. We implement this for stat, fstat, and lstat.
Currently, this is only tested on linux, but presumably would work with other OSes too.