diff options
author | Dodji Seketeli <dodji@redhat.com> | 2017-11-21 11:09:00 +0100 |
---|---|---|
committer | Dodji Seketeli <dodji@redhat.com> | 2017-11-21 11:09:00 +0100 |
commit | 933c7440343af55ffdbcc226507e53d941d772f5 (patch) | |
tree | 86ce8a84a3d1ce9c75502daf3731370dea44fc8e /ChangeLog | |
parent | Support systems where fts.h can't be used with _FILE_OFFSET_BITS set (diff) | |
download | libabigail-933c7440343af55ffdbcc226507e53d941d772f5.tar.gz libabigail-933c7440343af55ffdbcc226507e53d941d772f5.tar.bz2 libabigail-933c7440343af55ffdbcc226507e53d941d772f5.tar.xz |
Bug 22438 - Emit a clear message when debug info is not found
The alternate debug info file referred to a binary can be missing,
even though the rest of the debug info is not. In that case,
libabigail starts loading the debug info and then it crashes when
trying to get DIEs that are part of the missing alternate debug info.
This patch detects when the alternate debug info is missing, so that
abidiff and abipkgdiff can gracefully bail out, yielding a meaningful
error message.
* include/abg-dwarf-reader.h (enum abigail::dwarf_reader::status):
Add a new STATUS_ALT_DEBUG_INFO_NOT_FOUND enumerator there.
(refers_to_alt_debug_info): Declare new function.
* src/abg-dwarf-reader.cc (read_corpus_from_elf): Detect when the
referred-to alternate debug info file is not found and flip the
STATUS_ALT_DEBUG_INFO_NOT_FOUND bit of the status accordingly. If
the debug info was found but not the alternate debug info, then do
not try to read the debug info at all.
(refers_to_alt_debug_info): Define new function.
* tools/abidiff.cc (handle_error): Define new static function.
(main): Use it, rather than handling errors preventing libabigail
from reading the corpus on a case by case basis.
tools/abipkgdiff.cc (compare): Handle the case where no alternate
debug info was found.
* tests/data/test-diff-pkg/libxfce4ui-devel-4.12.1-8.fc27.ppc64-self-report-0.txt:
New test output reference.
* tests/data/test-diff-pkg/libxfce4ui-devel-4.12.1-8.fc27.ppc64.rpm:
New test input RPM.
* tests/data/test-diff-pkg/libxfce4ui-devel-debuginfo-4.12.1-8.fc27.ppc64.rpm:
Likewise.
* tests/data/Makefile.am: Add the new test files above to source
distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add a new test case from
the new input files above.
Signed-off-by: Dodji Seketeli <dodji@redhat.com>
Diffstat (limited to 'ChangeLog')
0 files changed, 0 insertions, 0 deletions