Fix uid64 to uid32 calculation