Fix Windows build, broken by the inclusion of sys/ioctl.h and isatty()