adapt for Windows