Skip to content

Commit

Permalink
cuda: fix error handling for setup_binsize
Browse files Browse the repository at this point in the history
We don't want to set `ier` to the CUDA error since it will be passed on
to the user.
  • Loading branch information
janden committed Oct 15, 2024
1 parent c0326ba commit 19a60eb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion include/cufinufft/impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,8 @@ int cufinufft_makeplan_impl(int type, int dim, int *nmodes, int iflag, int ntran
}

cufinufft_setup_binsize<T>(type, d_plan->spopts.nspread, dim, &d_plan->opts);
if (ier = cudaGetLastError(), ier != cudaSuccess) {
if (cudaGetLastError() != cudaSuccess) {
ier = FINUFFT_ERR_CUDA_FAILURE;
goto finalize;
}
if (d_plan->opts.debug) {
Expand Down

0 comments on commit 19a60eb

Please sign in to comment.