fixed compiling errors on win32