Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions opal/mca/pmix/pmix2x/pmix/VERSION
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ greek=
# command, or with the date (if "git describe" fails) in the form of
# "date<date>".

repo_rev=gitc2e543b
repo_rev=gitdff97ad

# If tarball_version is not empty, it is used as the version string in
# the tarball filename, regardless of all other versions listed in
Expand All @@ -44,7 +44,7 @@ tarball_version=

# The date when this release was created

date="Aug 10, 2016"
date="Aug 11, 2016"

# The shared library version of each of PMIx's public libraries.
# These versions are maintained in accordance with the "Library
Expand Down
23 changes: 16 additions & 7 deletions opal/mca/pmix/pmix2x/pmix/src/buffer_ops/copy.c
Original file line number Diff line number Diff line change
Expand Up @@ -679,11 +679,15 @@ pmix_status_t pmix_value_xfer(pmix_value_t *p, pmix_value_t *src)
memcpy(p->data.darray.array, src->data.darray.array, src->data.darray.size * sizeof(pmix_persistence_t));
break;
case PMIX_POINTER:
p->data.darray.array = (void**)malloc(src->data.darray.size * sizeof(void*));
p->data.darray.array = (char**)malloc(src->data.darray.size * sizeof(char*));
if (NULL == p->data.darray.array) {
return PMIX_ERR_NOMEM;
}
memcpy(p->data.darray.array, src->data.darray.array, src->data.darray.size * sizeof(void*));
prarray = (char**)p->data.darray.array;
strarray = (char**)src->data.darray.array;
for (n=0; n < src->data.darray.size; n++) {
prarray[n] = strarray[n];
}
break;
case PMIX_SCOPE:
p->data.darray.array = (pmix_scope_t*)malloc(src->data.darray.size * sizeof(pmix_scope_t));
Expand Down Expand Up @@ -1135,6 +1139,8 @@ pmix_status_t pmix_bfrop_copy_darray(pmix_data_array_t **dest,
sv = (pmix_value_t*)src->array;
for (n=0; n < src->size; n++) {
if (PMIX_SUCCESS != (rc = pmix_value_xfer(&pv[n], &sv[n]))) {
PMIX_VALUE_FREE(pv, src->size);
free(p);
return rc;
}
}
Expand Down Expand Up @@ -1265,6 +1271,8 @@ pmix_status_t pmix_bfrop_copy_darray(pmix_data_array_t **dest,
return PMIX_ERR_NOMEM;
}
if (PMIX_SUCCESS != (rc = pmix_value_xfer(pk[n].value, sk[n].value))) {
PMIX_VALUE_FREE(pk[n].value, 1);
free(p);
return rc;
}
}
Expand All @@ -1283,6 +1291,7 @@ pmix_status_t pmix_bfrop_copy_darray(pmix_data_array_t **dest,
if (NULL != sm[n].blob && 0 < sm[n].size) {
pm[n].blob = (uint8_t*)malloc(sm[n].size);
if (NULL == pm[n].blob) {
PMIX_MODEX_FREE(pm, src->size);
free(p);
return PMIX_ERR_NOMEM;
}
Expand All @@ -1303,12 +1312,12 @@ pmix_status_t pmix_bfrop_copy_darray(pmix_data_array_t **dest,
memcpy(p->array, src->array, src->size * sizeof(pmix_persistence_t));
break;
case PMIX_POINTER:
p->array = (void**)malloc(src->size * sizeof(void*));
if (NULL == p->array) {
free(p);
return PMIX_ERR_NOMEM;
p->array = (char**)malloc(src->size * sizeof(char*));
prarray = (char**)p->array;
strarray = (char**)src->array;
for (n=0; n < src->size; n++) {
prarray[n] = strarray[n];
}
memcpy(p->array, src->array, src->size * sizeof(void*));
break;
case PMIX_SCOPE:
p->array = (pmix_scope_t*)malloc(src->size * sizeof(pmix_scope_t));
Expand Down
5 changes: 4 additions & 1 deletion opal/mca/pmix/pmix2x/pmix/src/client/pmix_client_get.c
Original file line number Diff line number Diff line change
Expand Up @@ -392,6 +392,7 @@ static pmix_status_t process_val(pmix_value_t *val,
{
pmix_info_t *info;
size_t n, nsize, nvals;
pmix_status_t rc;

if (NULL == val) {
/* this is an error */
Expand All @@ -418,7 +419,9 @@ static pmix_status_t process_val(pmix_value_t *val,
}
nvals = 0;
for (n=0; n < nsize; n++) {
pmix_pointer_array_add(results, &info[n]);
if (PMIX_SUCCESS != (rc = pmix_pointer_array_add(results, &info[n]))) {
return rc;
}
++nvals;
}
if (PMIX_DATA_ARRAY == val->type) {
Expand Down
6 changes: 4 additions & 2 deletions opal/mca/pmix/pmix2x/pmix/src/tool/pmix_tool.c
Original file line number Diff line number Diff line change
Expand Up @@ -233,9 +233,11 @@ PMIX_EXPORT int PMIx_tool_init(pmix_proc_t *proc,
} else if (strcmp(info[n].key, PMIX_CONNECT_SYSTEM_FIRST) == 0) {
connect_to_system_first = info[n].value.data.flag;
connection_defined = true;
} else if (strcmp(info[n].key, PMIX_SERVER_TMPDIR) == 0) {
} else if (strcmp(info[n].key, PMIX_SERVER_TMPDIR) == 0 &&
NULL == mytmpdir) {
mytmpdir = strdup(info[n].value.data.string);
} else if (strcmp(info[n].key, PMIX_SYSTEM_TMPDIR) == 0) {
} else if (strcmp(info[n].key, PMIX_SYSTEM_TMPDIR) == 0 &&
NULL == systmpdir) {
systmpdir = strdup(info[n].value.data.string);
}
}
Expand Down