Fix for broken /dev/tty on Cygwin