new version to adapt to windows