fix for tty