Reverting changes from a pull request that caused compile errors for WIN32