Make sure to call wait() on all threads before exiting