hopefully fix some random crashes on disconnect on the osx client