/* Note: before conversion, these will be set to values that will be
immediately invalidated by the conversion process, but the conversion
- process will call ctf_set_base() again to fix things up. */
+ process will call ctf_set_base() again to fix things up.
+
+ These labels are explicitly constrained from being deduplicated (even though
+ .ctf is usually a duplicated name), because they are the key to identifying
+ the parent dict (and determining that this dict is a child) in the first
+ place. */
if (hp->cth_parlabel != 0)
fp->ctf_parlabel = ctf_strptr (fp, hp->cth_parlabel);
hdrp = (ctf_header_t *) buf;
if ((fp->ctf_flags & LCTF_CHILD) && (fp->ctf_parname != NULL))
- ctf_str_add_ref (fp, fp->ctf_parname, &hdrp->cth_parname);
+ ctf_str_add_no_dedup_ref (fp, fp->ctf_parname, &hdrp->cth_parname);
if (fp->ctf_cuname != NULL)
- ctf_str_add_ref (fp, fp->ctf_cuname, &hdrp->cth_cuname);
+ ctf_str_add_no_dedup_ref (fp, fp->ctf_cuname, &hdrp->cth_cuname);
if (ctf_emit_symtypetab_sects (fp, &symstate, &t, objt_size, func_size,
objtidx_size, funcidx_size) < 0)
pulled in.)
Note that the *final strtab* may be entirely empty, if all its strings are
- shared with the parent: the atoms table is a superset. */
+ shared with the parent: the atoms table is a superset. (But this will never
+ happen in practice, because some header fields are explicitly never
+ deduplicated.) */
int
ctf_str_create_atoms (ctf_dict_t *fp)
{