Protect against NULL cpuset when not bound
This commit was SVN r31600.
Этот коммит содержится в:
родитель
0209cddb5b
Коммит
c1383ca1f3
@ -294,18 +294,20 @@ int orte_ess_base_proc_binding(void)
|
|||||||
/* store our cpuset for exchange with non-peers
|
/* store our cpuset for exchange with non-peers
|
||||||
* so that other procs in a comm_spawn can know it
|
* so that other procs in a comm_spawn can know it
|
||||||
*/
|
*/
|
||||||
OBJ_CONSTRUCT(&kv, opal_value_t);
|
if (NULL != orte_process_info.cpuset) {
|
||||||
kv.key = strdup(OPAL_DSTORE_CPUSET);
|
OBJ_CONSTRUCT(&kv, opal_value_t);
|
||||||
kv.type = OPAL_STRING;
|
kv.key = strdup(OPAL_DSTORE_CPUSET);
|
||||||
kv.data.string = strdup(orte_process_info.cpuset);
|
kv.type = OPAL_STRING;
|
||||||
if (OPAL_SUCCESS != (ret = opal_dstore.store(opal_dstore_nonpeer,
|
kv.data.string = strdup(orte_process_info.cpuset);
|
||||||
(opal_identifier_t*)ORTE_PROC_MY_NAME,
|
if (OPAL_SUCCESS != (ret = opal_dstore.store(opal_dstore_nonpeer,
|
||||||
&kv))) {
|
(opal_identifier_t*)ORTE_PROC_MY_NAME,
|
||||||
ORTE_ERROR_LOG(ret);
|
&kv))) {
|
||||||
|
ORTE_ERROR_LOG(ret);
|
||||||
|
OBJ_DESTRUCT(&kv);
|
||||||
|
goto error;
|
||||||
|
}
|
||||||
OBJ_DESTRUCT(&kv);
|
OBJ_DESTRUCT(&kv);
|
||||||
goto error;
|
|
||||||
}
|
}
|
||||||
OBJ_DESTRUCT(&kv);
|
|
||||||
return ORTE_SUCCESS;
|
return ORTE_SUCCESS;
|
||||||
|
|
||||||
error:
|
error:
|
||||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user