]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
libctf: do not deduplicate strings in the header
authorNick Alcock <nick.alcock@oracle.com>
Mon, 15 Jul 2024 21:08:10 +0000 (22:08 +0100)
committerNick Alcock <nick.alcock@oracle.com>
Fri, 28 Feb 2025 14:47:24 +0000 (14:47 +0000)
commitba66e0cc32d749119485025e7f050021094e1b15
tree1d353174020f8b3352574e1da2d7b0cdcd7c127b
parent3bec4f1f3cbdb04c24c5601a5005db15b0793000
libctf: do not deduplicate strings in the header

It is unreasonable to expect users to ctf_import the parent before being
able to understand the header -- doubly so because the only string in the
header which is likely to be deduplicable is the parent name, which is the
same in every child, yet without the parent name being *available* in the
child's strtab you cannot call ctf_parent_name to figure out which parent
to import!

libctf/
* ctf-serialize.c (ctf_preserialize): Prevent deduplication of header string
        fields.
* ctf-open.c (ctf_set_base): Note this.
* ctf-string.c (ctf_str_free_atom): Likewise.
libctf/ctf-open.c
libctf/ctf-serialize.c
libctf/ctf-string.c