Visual Studio 2012 fixes