binutils-gdb/libctf
Nick Alcock 61914bb699
libctf: failure to open parent dicts that exist should be an error
CTF archive member opening (via ctf_arc_open_by_name, ctf_archive_iter, et
al) attempts to be helpful and auto-open and import any needed parent dict
in the same archive.  But if this fails, the error is not reported but
simply discarded, and you silently get back a dict with no parent, that
*you* suddenly have to remember to import.

This is not helpful behaviour: if the parent is corrupted or we run out of
memory or something, the caller is going to want to know!  Split it in two:
if the dict cites a parent that doesn't exist at all (a lot of historic
dicts name "PARENT" as their parent, even when they're not even children, or
perhaps the parent dict is stored separately and you plan to manually
associate it), we skip it as now, but if the import fails with an actual
error other than ECTF_ARNNAME, return the error and fail the open.

libctf/
	* ctf-archive.c (ctf_arc_import_parent):  Return failure if
        parent opening fails for reasons other thnn nonexistence.
	(ctf_dict_open_sections): Adjust.
2024-05-17 12:58:17 +01:00
..
doc Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
testsuite buffer overflow in libctf tests 2024-04-24 09:33:03 +09:30
.gitignore libctf: restructure error handling to reduce relocations 2020-07-22 17:57:20 +01:00
aclocal.m4 mmap: Avoid the sanitizer configure check failure 2024-04-10 03:57:46 -07:00
ChangeLog Add markers for 2.42 branch 2024-01-15 14:42:15 +00:00
ChangeLog-2020 libctf: fix old ChangeLog typo 2021-01-05 14:53:40 +00:00
config.h.in Finalized intl-update patches 2023-11-15 12:53:04 +00:00
configure libctf: do not include undefined functions in libctf.ver 2024-04-19 16:14:48 +01:00
configure.ac libctf: do not include undefined functions in libctf.ver 2024-04-19 16:14:48 +01:00
ctf-archive.c libctf: failure to open parent dicts that exist should be an error 2024-05-17 12:58:17 +01:00
ctf-create.c libctf: make ctf_serialize() actually serialize 2024-04-19 16:14:47 +01:00
ctf-decl.c Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
ctf-decls.h Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
ctf-dedup.c libctf: don't pass errno into ctf_err_warn so often 2024-04-19 16:14:48 +01:00
ctf-dump.c libctf: improve handling of type dumping errors 2024-04-19 16:14:47 +01:00
ctf-endian.h Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
ctf-error.c Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
ctf-hash.c Revert "libctf: do not corrupt strings across ctf_serialize" 2024-04-19 16:14:46 +01:00
ctf-impl.h libctf: make ctf_serialize() actually serialize 2024-04-19 16:14:47 +01:00
ctf-inlines.h Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
ctf-intl.h Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
ctf-labels.c Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
ctf-link.c libctf: don't pass errno into ctf_err_warn so often 2024-04-19 16:14:48 +01:00
ctf-lookup.c libctf: don't pass errno into ctf_err_warn so often 2024-04-19 16:14:48 +01:00
ctf-open-bfd.c Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
ctf-open.c libctf: typos 2024-05-17 12:58:17 +01:00
ctf-qsort_r.c Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
ctf-serialize.c libctf: make ctf_serialize() actually serialize 2024-04-19 16:14:47 +01:00
ctf-sha1.c Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
ctf-sha1.h Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
ctf-string.c libctf: make ctf_serialize() actually serialize 2024-04-19 16:14:47 +01:00
ctf-subr.c libctf: don't pass errno into ctf_err_warn so often 2024-04-19 16:14:48 +01:00
ctf-types.c libctf: support addition of types to dicts read via ctf_open() 2024-04-19 16:14:46 +01:00
ctf-util.c libctf: replace 'pending refs' abstraction 2024-04-19 16:14:46 +01:00
elf.h Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
libctf.ver libctf: Remove undefined functions from ver. map 2024-04-19 16:14:48 +01:00
Makefile.am Update year range in copyright notice of binutils files 2024-01-04 22:58:12 +10:30
Makefile.in mmap: Avoid the sanitizer configure check failure 2024-04-10 03:57:46 -07:00
NEWS include, libctf, ld: extend variable section to contain functions too 2022-03-23 13:48:32 +00:00
swap.h libctf warnings 2024-04-17 09:24:36 +09:30