Fixed MSVC problems