1
1

Better check for NULL before using the value

This commit was SVN r24122.
Этот коммит содержится в:
Ralph Castain 2010-12-01 04:48:50 +00:00
родитель c56185887b
Коммит 85a974b0de

Просмотреть файл

@ -205,6 +205,13 @@ int orte_rmcast_base_process_msg(opal_buffer_t *msg)
recv = ptr;
break;
}
if (NULL == recv) {
/* recv not found - dump msg */
ORTE_RELEASE_THREAD(&orte_rmcast_base.main_ctl);
goto cleanup;
}
if (!(ORTE_RMCAST_PERSISTENT & recv->flags)) {
OPAL_OUTPUT_VERBOSE((2, orte_rmcast_base.rmcast_output,
"%s rmcast:base:process_recv removing non-persistent recv",
@ -213,11 +220,6 @@ int orte_rmcast_base_process_msg(opal_buffer_t *msg)
}
ORTE_RELEASE_THREAD(&orte_rmcast_base.main_ctl);
if (NULL == recv) {
/* recv not found - dump msg */
goto cleanup;
}
OPAL_OUTPUT_VERBOSE((2, orte_rmcast_base.rmcast_output,
"%s rmcast:base:process_recv delivering message to channel %d tag %d",
ORTE_NAME_PRINT(ORTE_PROC_MY_NAME), recv->channel, (int)tag));