MacOS 10.8 compilation fix