Let thread exit when Ctrl-C