fixed 32/64 bit bug