Skip to content

Commit fc32bfe

Browse files
authored
Merge pull request #12847 from devreal/info-public-dup-references
Retain info references on public info dup
2 parents f8083d2 + 89eb96d commit fc32bfe

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

opal/util/info.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,11 @@ static int opal_info_dup_impl(opal_info_t *info, opal_info_t **newinfo, bool pub
8282
newentry->ie_key = iterator->ie_key;
8383
OBJ_RETAIN(iterator->ie_key);
8484
newentry->ie_value = iterator->ie_value;
85+
if (public_only) {
86+
/* for public info-dup we also duplicate the references so that subsequent
87+
* duplications see the same info keys */
88+
newentry->ie_referenced = iterator->ie_referenced;
89+
}
8590
OBJ_RETAIN(iterator->ie_value);
8691
opal_list_append (&((*newinfo)->super), (opal_list_item_t *) newentry);
8792
}

0 commit comments

Comments
 (0)