ff function for osx