Fix Windows 7 problems