resolve issue when init fails - component is unloaded - needed to remove component list entry
This commit was SVN r2118.
Этот коммит содержится в:
родитель
3fe4447ae4
Коммит
c4bada809d
@ -33,10 +33,11 @@ int mca_ptl_base_select(bool *allow_multi_user_threads,
|
|||||||
/* Traverse the list of opened modules; call their init
|
/* Traverse the list of opened modules; call their init
|
||||||
functions. */
|
functions. */
|
||||||
|
|
||||||
for (item = ompi_list_get_first(&mca_ptl_base_components_opened);
|
item = ompi_list_get_first(&mca_ptl_base_components_opened);
|
||||||
item != ompi_list_get_end(&mca_ptl_base_components_opened);
|
while(item != ompi_list_get_end(&mca_ptl_base_components_opened)) {
|
||||||
item = ompi_list_get_next(item)) {
|
ompi_list_item_t *next = ompi_list_get_next(item);
|
||||||
cli = (mca_base_component_list_item_t *) item;
|
cli = (mca_base_component_list_item_t *) item;
|
||||||
|
|
||||||
component = (mca_ptl_base_component_t *) cli->cli_component;
|
component = (mca_ptl_base_component_t *) cli->cli_component;
|
||||||
|
|
||||||
ompi_output_verbose(10, mca_ptl_base_output,
|
ompi_output_verbose(10, mca_ptl_base_output,
|
||||||
@ -56,11 +57,12 @@ int mca_ptl_base_select(bool *allow_multi_user_threads,
|
|||||||
if (NULL == modules) {
|
if (NULL == modules) {
|
||||||
ompi_output_verbose(10, mca_ptl_base_output,
|
ompi_output_verbose(10, mca_ptl_base_output,
|
||||||
"select: init returned failure");
|
"select: init returned failure");
|
||||||
|
|
||||||
mca_base_component_repository_release((mca_base_component_t *) component);
|
|
||||||
ompi_output_verbose(10, mca_ptl_base_output,
|
ompi_output_verbose(10, mca_ptl_base_output,
|
||||||
"select: module %s unloaded",
|
"select: module %s unloaded",
|
||||||
component->ptlm_version.mca_component_name);
|
component->ptlm_version.mca_component_name);
|
||||||
|
|
||||||
|
mca_base_component_repository_release((mca_base_component_t *) component);
|
||||||
|
ompi_list_remove_item(&mca_ptl_base_components_opened, item);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Otherwise, it initialized properly. Save it. */
|
/* Otherwise, it initialized properly. Save it. */
|
||||||
@ -86,6 +88,7 @@ int mca_ptl_base_select(bool *allow_multi_user_threads,
|
|||||||
free(modules);
|
free(modules);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
item = next;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Finished querying all components. Check for the bozo case. */
|
/* Finished querying all components. Check for the bozo case. */
|
||||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user