fixed MSVC specific compile issues