fix bug, thread not exit normally