diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index 7e098085e8..1a61f5b08f 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -241,6 +241,10 @@ Application::Application(int& argc, char** argv, timeval &startup_time) : } Application::~Application() { + // ask the audio thread to quit and wait until it is done + _audio.thread()->quit(); + _audio.thread()->wait(); + storeSizeAndPosition(); NodeList::getInstance()->removeHook(&_voxels); NodeList::getInstance()->removeHook(this);