Fixes for msvc2010