Move tty lookup/reopen to caller