break tty loop if child sends eof