* [PATCH, applied] elf-reader: Avoid crashing when looking at non-existing variable symbol
@ 2024-05-09 22:32 Dodji Seketeli
0 siblings, 0 replies; only message in thread
From: Dodji Seketeli @ 2024-05-09 22:32 UTC (permalink / raw)
To: libabigail
Hello,
* src/abg-elf-reader.cc (reader::variable_symbol_is_exported): Do
not crash when the symbol we are looking at is non-present.
Signed-off-by: Dodji Seketeli <dodji@redhat.com>
Applied to master branch.
---
src/abg-elf-reader.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/abg-elf-reader.cc b/src/abg-elf-reader.cc
index 80720716..610f8617 100644
--- a/src/abg-elf-reader.cc
+++ b/src/abg-elf-reader.cc
@@ -874,7 +874,7 @@ elf_symbol_sptr
reader::variable_symbol_is_exported(const string& name) const
{
const elf_symbol_sptr s = symtab()->variable_symbol_is_exported(name);
- if (s->is_variable() && s->is_public())
+ if (s && s->is_variable() && s->is_public())
{
bool looking_at_linux_kernel_binary =
(load_in_linux_kernel_mode()
--
2.39.3
--
Dodji
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2024-05-09 22:32 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-05-09 22:32 [PATCH, applied] elf-reader: Avoid crashing when looking at non-existing variable symbol Dodji Seketeli
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).