Made code compatible with windows.