Added trap for Ctrl-C signal. On lab machines, this was causing STDIN to end up closed for the terminal when serialT was closed in this manner. The handler for the signal, restores STDIN and then exits.