public inbox for libabigail@sourceware.org
 help / color / mirror / Atom feed
From: Dodji Seketeli <dodji@redhat.com>
To: libabigail@sourceware.org
Subject: [PATCH, applied] Bug 29690 - Out of range exception in add_or_update_class_type
Date: Mon, 27 Mar 2023 11:21:18 +0200	[thread overview]
Message-ID: <87lejimtwx.fsf@redhat.com> (raw)

hello,

This was triggered by doing:

    $ fedabipkgdiff  --self-compare -a --from fc37 amg4psblas-mpich

	* src/abg-dwarf-reader.cc (add_or_update_class_type): Make sure
	the array is big enough.

Signed-off-by: Dodji Seketeli <dodji@redhat.com>
---
 src/abg-dwarf-reader.cc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/abg-dwarf-reader.cc b/src/abg-dwarf-reader.cc
index d842d25b..37367dba 100644
--- a/src/abg-dwarf-reader.cc
+++ b/src/abg-dwarf-reader.cc
@@ -13075,6 +13075,7 @@ add_or_update_class_type(reader&	 rdr,
 	      /// "_vptr[^0-9a-zA-Z_]", which is what Clang and GCC
 	      /// use as a name for the hidden vtable pointer.
 	      if (n.substr(0, 5) == "_vptr"
+		  && n.size() > 5
 		  && !std::isalnum(n.at(5))
 		  && n.at(5) != '_')
 		continue;
-- 
2.39.2


-- 
		Dodji


                 reply	other threads:[~2023-03-27  9:21 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87lejimtwx.fsf@redhat.com \
    --to=dodji@redhat.com \
    --cc=libabigail@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).