emacs: fix support for windows I/O