Fix an initialization problem that valgrind complained about - forgot to mirror the fix that was done for the replica.
This commit was SVN r3646.
Этот коммит содержится в:
родитель
48b0b10464
Коммит
73844230bc
@ -178,6 +178,7 @@ mca_gpr_base_module_t* mca_gpr_proxy_init(bool *allow_multi_user_threads, bool *
|
||||
/* initialize the registry compound mode */
|
||||
mca_gpr_proxy_compound_cmd_mode = false;
|
||||
mca_gpr_proxy_compound_cmd_waiting = 0;
|
||||
mca_gpr_proxy_compound_cmd = NULL;
|
||||
|
||||
/* define the replica for us to use - get it from process_info */
|
||||
mca_gpr_my_replica = ompi_name_server.copy_process_name(ompi_process_info.gpr_replica);
|
||||
|
@ -29,10 +29,13 @@ int mca_gpr_proxy_begin_compound_cmd(void)
|
||||
}
|
||||
|
||||
mca_gpr_proxy_compound_cmd_mode = true;
|
||||
if (NULL != mca_gpr_proxy_compound_cmd) { /* first time through, pointer is NULL, so just perform init */
|
||||
ompi_buffer_size(mca_gpr_proxy_compound_cmd, &size);
|
||||
if (0 < size) {
|
||||
ompi_buffer_free(mca_gpr_proxy_compound_cmd);
|
||||
}
|
||||
}
|
||||
|
||||
ompi_buffer_init(&mca_gpr_proxy_compound_cmd, 0);
|
||||
|
||||
OMPI_THREAD_UNLOCK(&mca_gpr_proxy_wait_for_compound_mutex);
|
||||
@ -47,10 +50,12 @@ int mca_gpr_proxy_stop_compound_cmd(void)
|
||||
OMPI_THREAD_LOCK(&mca_gpr_proxy_wait_for_compound_mutex);
|
||||
|
||||
mca_gpr_proxy_compound_cmd_mode = false;
|
||||
if (NULL != mca_gpr_proxy_compound_cmd) {
|
||||
ompi_buffer_size(mca_gpr_proxy_compound_cmd, &size);
|
||||
if (0 < size) {
|
||||
ompi_buffer_free(mca_gpr_proxy_compound_cmd);
|
||||
}
|
||||
}
|
||||
|
||||
if (mca_gpr_proxy_compound_cmd_waiting) {
|
||||
ompi_condition_signal(&mca_gpr_proxy_compound_cmd_condition);
|
||||
@ -101,10 +106,13 @@ ompi_list_t* mca_gpr_proxy_exec_compound_cmd(bool return_requested)
|
||||
|
||||
CLEANUP:
|
||||
mca_gpr_proxy_compound_cmd_mode = false;
|
||||
if (NULL != mca_gpr_proxy_compound_cmd) { /* shouldn't be any way this could be true, but just to be safe... */
|
||||
ompi_buffer_size(mca_gpr_proxy_compound_cmd, &size);
|
||||
if (0 < size) {
|
||||
ompi_buffer_free(mca_gpr_proxy_compound_cmd);
|
||||
}
|
||||
}
|
||||
|
||||
if (mca_gpr_proxy_compound_cmd_waiting) {
|
||||
ompi_condition_signal(&mca_gpr_proxy_compound_cmd_condition);
|
||||
}
|
||||
|
Загрузка…
Ссылка в новой задаче
Block a user