Visual Studio compile fixes