Skip to content

Commit d81dc53

Browse files
committed
SPML/UCX: Fix coverity error
Signed-off-by: Mikhail Brinskii <mikhailb@mellanox.com>
1 parent 9442989 commit d81dc53

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

oshmem/mca/spml/ucx/spml_ucx.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -891,8 +891,10 @@ int mca_spml_ucx_put_all_nb(void *dest, const void *source, size_t size, long *c
891891
ctx = oshmem_ctx_default;
892892
}
893893

894+
assert(ctx != NULL); /* make coverity happy */
895+
894896
for (peer = 0; peer < oshmem_num_procs(); peer++) {
895-
dst_pe = (peer + my_pe) % oshmem_group_all->proc_count;
897+
dst_pe = (peer + my_pe) % oshmem_num_procs();
896898
rc = mca_spml_ucx_put_nb(ctx,
897899
(void*)((uintptr_t)dest + my_pe * size),
898900
size,

0 commit comments

Comments
 (0)