1
1

Ensure that endpoint->endpoint_addr is not NULL before trying to

derefence through it.  It is legal for endpoint_addr to be NULL in the
destructor because if btl_tcp_add_procs() -> btl_tcp_proc_insert()
returns UNREACH, then endpoint_addr will be NULL and we'll OBJ_RELEASE
it.

This commit was SVN r9940.
Этот коммит содержится в:
Jeff Squyres 2006-05-16 19:01:08 +00:00
родитель 1f8cc1af65
Коммит 7b59847765

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

@ -303,7 +303,12 @@ int mca_btl_tcp_proc_remove(mca_btl_tcp_proc_t* btl_proc, mca_btl_base_endpoint_
OBJ_RELEASE(btl_proc);
return OMPI_SUCCESS;
}
btl_endpoint->endpoint_addr->addr_inuse--;
/* The endpoint_addr may still be NULL if this enpoint is
being removed early in the wireup sequence (e.g., if it
is unreachable by all other procs) */
if (NULL != btl_endpoint->endpoint_addr) {
btl_endpoint->endpoint_addr->addr_inuse--;
}
break;
}
}