Updated using the old stat only on posix systems.