Fixed locale error on OSX