Skip to content
This repository has been archived by the owner on May 3, 2024. It is now read-only.

CORTX-26613 : Fix Codacy errors for net/libfab/libfab.c #2138

Merged
merged 1 commit into from
Sep 13, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions net/libfab/libfab.c
Original file line number Diff line number Diff line change
Expand Up @@ -2095,13 +2095,16 @@ static int libfab_buf_dom_reg(struct m0_net_buffer *nb, struct m0_fab__tm *tm)
int i;
int ret = 0;

M0_PRE(nb != NULL && nb->nb_dom != NULL && tm != NULL);
M0_PRE(nb != NULL && nb->nb_dom != NULL &&
nb->nb_xprt_private != NULL &&
nb->nb_dom->nd_xprt_private != NULL &&
tm != NULL && tm->ftm_fab != NULL &&
tm->ftm_fab->fab_dom != NULL);
fbp = nb->nb_xprt_private;
seg_nr = nb->nb_buffer.ov_vec.v_nr;
ndom = nb->nb_dom->nd_xprt_private;
dp = tm->ftm_fab->fab_dom;

M0_ASSERT(fbp != NULL && dp != NULL && ndom != NULL);
M0_ASSERT(seg_nr <= ndom->fnd_seg_nr);

mr = &fbp->fb_mr;
Expand Down