fix errors introduced by visual studio build