diff --git a/heu/library/algorithms/paillier_dl/cgbn_wrapper/cgbn_wrapper.cu.cc b/heu/library/algorithms/paillier_dl/cgbn_wrapper/cgbn_wrapper.cu.cc index 85866f1c..9c72fb19 100644 --- a/heu/library/algorithms/paillier_dl/cgbn_wrapper/cgbn_wrapper.cu.cc +++ b/heu/library/algorithms/paillier_dl/cgbn_wrapper/cgbn_wrapper.cu.cc @@ -73,9 +73,9 @@ static void store2host(MPInt *z, dev_mem_t *address) { CUDA_CHECK(cudaMemcpy(buffer.data(), address->_limbs, z_size, cudaMemcpyDeviceToHost)); int used = 0; - buf_cal_used((mp_digit *)buffer.data(), z_size / sizeof(mp_digit), &used); + buf_cal_used((uint64_t *)buffer.data(), z_size / sizeof(uint64_t), &used); - buffer.resize(used * sizeof(mp_digit)); + buffer.resize(used * sizeof(uint64_t)); Endian endian = Endian::little; (*z).FromMagBytes(buffer, endian); } @@ -738,4 +738,4 @@ void CGBNWrapper::StoreToHost(SecretKey *sk) { store2host(&sk->hq_, sk->dev_hq_); } -} // namespace heu::lib::algorithms::paillier_dl \ No newline at end of file +} // namespace heu::lib::algorithms::paillier_dl