Fix bugs on win64.