1
1

Fix a crash while closing libnbc

If the free list initialization fails in libnbc_open()
mca_coll_libnbc_component.active_requests remain uninitialized,
resulting in a crash while closing the component
Этот коммит содержится в:
Nysal Jan K.A 2015-02-11 21:50:46 +05:30
родитель 0ac2f08460
Коммит ded408f485

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

@ -88,13 +88,13 @@ libnbc_open(void)
int ret;
OBJ_CONSTRUCT(&mca_coll_libnbc_component.requests, opal_free_list_t);
OBJ_CONSTRUCT(&mca_coll_libnbc_component.active_requests, opal_list_t);
ret = opal_free_list_init (&mca_coll_libnbc_component.requests,
sizeof(ompi_coll_libnbc_request_t), 8,
OBJ_CLASS(ompi_coll_libnbc_request_t),
0, 0, 0, -1, 8, NULL, 0, NULL, NULL, NULL);
if (OMPI_SUCCESS != ret) return ret;
OBJ_CONSTRUCT(&mca_coll_libnbc_component.active_requests, opal_list_t);
/* note: active comms is the number of communicators who have had
a non-blocking collective started */
mca_coll_libnbc_component.active_comms = 0;