Update thread.h

Removed exit(0) in destructor.  Should work now