1
1

usnic: ensure to have a safe destruction of an opal_list_item_t

It turns out that we ''can'' get to the endpoint destructor with the
endpoint still on the "endpoints needing ACKs" list.  So if it's on
the list, remove it first, and then DESTRUCT the opal_list_item_t.

This prevents an assert() fail in debug builds.  We'd like to let this
soak over the weekend.

cmr=v1.8.2:reviewer=dgoodell

This commit was SVN r32546.
Этот коммит содержится в:
Jeff Squyres 2014-08-15 21:52:36 +00:00
родитель 1cdcb7290b
Коммит ac7c907f8d

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

@ -113,8 +113,9 @@ static void endpoint_destruct(mca_btl_base_endpoint_t* endpoint)
int rc;
opal_btl_usnic_proc_t *proc;
/* We should not get here for an endpoint that is on the ACK list,
so it should be safe to unconditionally destruct the ack_li */
if (endpoint->endpoint_ack_needed) {
opal_btl_usnic_remove_from_endpoints_needing_ack(endpoint);
}
OBJ_DESTRUCT(&(endpoint->endpoint_ack_li));
/* Remove the endpoint from the all_endpoints list */