]> git.ipfire.org Git - thirdparty/elfutils.git/commit
debuginfod: fix skipping <built-in> source file
authorOmar Sandoval <osandov@fb.com>
Tue, 23 Jul 2024 22:35:37 +0000 (15:35 -0700)
committerAaron Merey <amerey@redhat.com>
Wed, 24 Jul 2024 22:13:40 +0000 (18:13 -0400)
commit64186d7548db976caffa9d2ba210eed66cdc808f
treedbba025ded2af2788bd4982cc7a4b1bc8a8c17d6
parenta49d5c0e6dee7026c54699f6024ecd0a22a9aa5b
debuginfod: fix skipping <built-in> source file

dwarf_extract_source_paths explicitly skips source files that equal
"<built-in>", but dwarf_filesrc may return a path like "dir/<built-in>".
Check for and skip that case, too.

In particular, the test debuginfod RPMs have paths like this.  However,
the test cases didn't catch this because they have a bug, too: they
follow symlinks, which results in double-counting every file.  Fix that,
too.

Signed-off-by: Omar Sandoval <osandov@fb.com>
debuginfod/debuginfod.cxx
tests/run-debuginfod-archive-groom.sh
tests/run-debuginfod-extraction.sh