From 914cd22833ca1b4c0cc6fab111b0ab914b6f8aca Mon Sep 17 00:00:00 2001 From: bjarni Date: Fri, 30 Nov 2007 14:42:16 +0000 Subject: [PATCH] (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) --- src/unix.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/unix.cpp b/src/unix.cpp index aa9a361eb5..0dc98d63c6 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;