fix bug in unittest over x64 and x86 machine