Fixed compilation on Mac OS X