Skip to content

Commit 9145181

Browse files
committed
check right thing
MPI_T_CVAR_HANDLE_ALLOC and PVAR variant actually take a pointer to an MPI object handle not the handle itself. Do fix the check. Signed-off-by: Howard Pritchard <[email protected]>
1 parent dbb5e03 commit 9145181

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

ompi/mpi/tool/mpit_common.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,10 +97,13 @@ int ompit_opal_to_mpit_error (int rc)
9797
bool ompit_obj_invalid(void *obj_handle)
9898
{
9999
bool ret = true; /* by default return obj is invalid */
100-
opal_object_t *opal_obj = (opal_object_t *)obj_handle;
100+
opal_object_t *opal_obj = NULL;
101101
opal_class_t *opal_class;
102102
const char *obj_name = NULL;
103103

104+
/* we are actually evaulating a pointer to an OMPI MPI opaque handle */
105+
opal_obj = *(opal_object_t **)obj_handle;
106+
104107
/*
105108
* this should have already been checked by the caller but we it here too
106109
*/

0 commit comments

Comments
 (0)