diff options
Diffstat (limited to 'bfd/elfxx-riscv.c')
-rw-r--r-- | bfd/elfxx-riscv.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/bfd/elfxx-riscv.c b/bfd/elfxx-riscv.c index c89b1e5..94bff0e 100644 --- a/bfd/elfxx-riscv.c +++ b/bfd/elfxx-riscv.c @@ -1583,6 +1583,12 @@ riscv_release_subset_list (riscv_subset_list_t *subset_list) } subset_list->tail = NULL; + + if (subset_list->arch_str != NULL) + { + free ((void*) subset_list->arch_str); + subset_list->arch_str = NULL; + } } /* Parsing extension version. @@ -2138,6 +2144,7 @@ riscv_copy_subset_list (riscv_subset_list_t *subset_list) { riscv_subset_list_t *new = xmalloc (sizeof *new); new->head = riscv_copy_subset (new, subset_list->head); + new->arch_str = strdup (subset_list->arch_str); return new; } |