diff options
author | bjarni <bjarni@openttd.org> | 2007-11-30 14:42:16 +0000 |
---|---|---|
committer | bjarni <bjarni@openttd.org> | 2007-11-30 14:42:16 +0000 |
commit | 7162b8ddb3dc479cedb1e27e0390c97c7e3a1fc2 (patch) | |
tree | 207f5c5431863b30bee433889d01668f7e2d7006 /src | |
parent | 5fcbb8f59bdc442c09395aee62201ad905cab3b2 (diff) | |
download | openttd-7162b8ddb3dc479cedb1e27e0390c97c7e3a1fc2.tar.xz |
(svn r11541) -Fix: [OSX] detect statvfs at runtime (based on OSX version) instead of compile time
This should prevent a crash on OSX 10.3 with the precompiled binaries (in the load/save windows)
Diffstat (limited to 'src')
-rw-r--r-- | src/unix.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/unix.cpp b/src/unix.cpp index aa9a361eb..0dc98d63c 100644 --- a/src/unix.cpp +++ b/src/unix.cpp @@ -67,6 +67,10 @@ bool FiosGetDiskFreeSpace(const char *path, uint32 *tot) uint32 free = 0; #ifdef HAS_STATVFS +# ifdef __APPLE__ + /* OSX 10.3 lacks statvfs so don't try to use it even though later versions of OSX has it. */ + if (MacOSVersionIsAtLeast(10, 4, 0)) +# endif { struct statvfs s; |