Skip to content

Commit

Permalink
DAOS-16514 vos: fix coverity issue (#15083) (#15086)
Browse files Browse the repository at this point in the history
Fix coverity 2555843 explict null dereferenced.

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
  • Loading branch information
gnailzenh committed Sep 6, 2024
1 parent ee9a06d commit 70e4362
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/vos/vos_obj.c
Original file line number Diff line number Diff line change
Expand Up @@ -1700,7 +1700,8 @@ vos_obj_iter_prep(vos_iter_type_t type, vos_iter_param_t *param,
return -DER_NOMEM;

/* ip_hdl is dkey or akey tree open handle for vos_iterate_key() */
if (!(param->ip_flags & VOS_IT_KEY_TREE)) {
if (param->ip_flags != VOS_IT_KEY_TREE) {
D_ASSERT(!(param->ip_flags & VOS_IT_KEY_TREE));
cont = vos_hdl2cont(param->ip_hdl);
is_sysdb = cont->vc_pool->vp_sysdb;
dth = vos_dth_get(is_sysdb);
Expand Down

0 comments on commit 70e4362

Please sign in to comment.