OSX compilation fixed