Fix some crazy behaviour on osx. :bomb: