Fixed some errors while compiling on Windows.