fixes for msvc