fixed to win32. disabled the warning C4996 in vc++.