apparently w+ is necessary to create a file on osx