libabigail/tests/data/test-diff-pkg-ctf
Dodji Seketeli 3c33437ddf ctf-reader: Enumerate dicts in the archive rather than using their name
ctf::reader::process_ctf_archive calls ctf_dict_open with the name of
the (parent) dictionary to open.  If that parent dictionary is set to
an unexpected name, then the call to ctf_dict_open fails.  This can
happen for instance when at link time, the name of the parent
dictionary is set to an arbitrary name using the
"ctf_link_set_memb_name_changer" function.

This patch enumerates the dictionaries of the archive to avoid having
to know the name of the parent dictionary.  The enumeration is done
using the ctf_archive_next function of libctf.

There is currently no binary with an unexpected dictionary name in the
test suite so this patch cannot be tested for that particular case.
I'd be glad to have such binaries added to the test suite.

In the mean time this patch has been tested successfully using "make
fullcheck" on the existing test suite.

	* src/abg-ctf-reader.cc (reader::process_ctf_archive):  Do not use
	ctf_dict_open to open the dictionary by name.  Rather, enumerate
	the dictionaries of the current archive by using ctf_archive_next
	just like what lookup_symbol_in_ctf_archive does.  Set the
	argument of the skip_parent parameter to "false" to ensure we get
	the parent dictionary.
	(lookup_symbol_in_ctf_archive): Clean this up to properly
	initialize the parameters and to document the arguments to the
	parameters of ctf_archive_next.  Use nullptr instead of NULL.
	* tests/data/test-diff-pkg-ctf/test-rpm-report-1.txt: Adjust.
	* tests/data/test-diff-pkg-ctf/test-rpm-report-2.txt: Adjust.

Signed-off-by: Dodji Seketeli <dodji@redhat.com>
2024-08-20 19:37:56 +02:00
..
dirpkg-0-dir1
dirpkg-0-dir2
dirpkg-1-dir1
dirpkg-1-dir2
dirpkg-2-dir1
dirpkg-2-dir2
dirpkg-3-dir1
dirpkg-3-dir2
symlink-dir-test1
cracklib-2.9.6-15-ol8.x86_64-report-0.txt
cracklib-2.9.6-15-ol8u0.x86_64.rpm
cracklib-2.9.6-15-ol8u6.x86_64.rpm
dirpkg-0-report-0.txt
dirpkg-1-report-0.txt
dirpkg-1-report-1.txt
dirpkg-2-report-0.txt
dirpkg-3-report-0.txt
dirpkg-3-report-1.txt ctf-reader: Set alignment-in-bits property to 0 2022-11-29 12:44:16 +01:00
dirpkg-3-report-2.txt ctf-reader: Set alignment-in-bits property to 0 2022-11-29 12:44:16 +01:00
dirpkg-3.suppr
elfutils-libelf-0.186-1.x86_64.rpm
elfutils-libelf-0.186-2.x86_64.rpm
elfutils-libelf-0.186-report-0.txt
elfutils-libelf-0.186-report-1.txt
gmp-6.1.2-8-ol8u0.x86_64.rpm
gmp-6.2.0-10-ol9u0.x86_64.rpm
gmp-6.x.x86_64-report-0.txt ir: Don't strip typedefs from parms and return type when comparing fns 2024-07-16 12:32:32 +02:00
isl-0.16.1-6.x86_64.rpm
isl-0.16.1-7.x86_64.rpm
isl-0.16.1-report-0.txt
isl-debuginfo-0.16.1-6.x86_64.rpm
isl-debuginfo-0.16.1-7.x86_64.rpm
libdwarf-20180129-4-no-ctf.x86_64.rpm
libdwarf-20180129-4.x86_64.rpm
libdwarf-20180129-5-no-ctf.x86_64.rpm
libdwarf-20180129-5.x86_64.rpm
symlink-dir-test1-report0.txt
symlink-dir-test1-report1.txt abipkgdiff: Avoid comparing binaries that are outside of the package 2023-09-07 15:23:38 +02:00
tarpkg-0-dir1.ta
tarpkg-0-dir1.tar
tarpkg-0-dir1.tar.bz2
tarpkg-0-dir1.tar.gz
tarpkg-0-dir2.ta
tarpkg-0-dir2.tar
tarpkg-0-dir2.tar.bz2
tarpkg-0-dir2.tar.gz
tarpkg-0-report-0.txt
tarpkg-1-dir1.tar.gz
tarpkg-1-dir2.tar.gz
tarpkg-1-report-0.txt
test-rpm-report-0.txt Improve type naming 2023-12-01 15:43:53 +01:00
test-rpm-report-1.txt ctf-reader: Enumerate dicts in the archive rather than using their name 2024-08-20 19:37:56 +02:00
test-rpm-report-2.txt ctf-reader: Enumerate dicts in the archive rather than using their name 2024-08-20 19:37:56 +02:00
test-rpm-report-3.txt
test-rpm-report-4.txt
test-rpm-report-5.txt