public inbox for gdb-prs@sourceware.org help / color / mirror / Atom feed
From: "vries at gcc dot gnu.org" <sourceware-bugzilla@sourceware.org> To: gdb-prs@sourceware.org Subject: [Bug ada/31648] [gdb/ada] segfault in coerce_ref Date: Thu, 18 Apr 2024 07:54:10 +0000 [thread overview] Message-ID: <bug-31648-4717-Ac9tGebKmG@http.sourceware.org/bugzilla/> (raw) In-Reply-To: <bug-31648-4717@http.sourceware.org/bugzilla/> https://sourceware.org/bugzilla/show_bug.cgi?id=31648 --- Comment #4 from Tom de Vries <vries at gcc dot gnu.org> --- With this: ... diff --git a/gdb/valops.c b/gdb/valops.c index a17b937a963..90be1c0a86b 100644 --- a/gdb/valops.c +++ b/gdb/valops.c @@ -2330,6 +2330,9 @@ value_struct_elt (struct value **argp, struct type *t; struct value *v; + if (*argp == nullptr) + error (_("%s"), err); + *argp = coerce_array (*argp); t = check_typedef ((*argp)->type ()); ... we have instead: ... $ gdb -q -batch -ex "set trace-commands on" -x gdb.in +file foo_n207_004 +break foo_n207_004.adb:25 Breakpoint 1 at 0x401cc0: file /usr/src/packages/BUILD/gdb-13.2/gdb/testsuite/gdb.ada/tick_length_array_enum_idx/foo_n207_004.adb, line 25. +run Breakpoint 1, foo_n207_004 () at /usr/src/packages/BUILD/gdb-13.2/gdb/testsuite/gdb.ada/tick_length_array_enum_idx/foo_n207_004.adb:25 warning: 25 /usr/src/packages/BUILD/gdb-13.2/gdb/testsuite/gdb.ada/tick_length_array_enum_idx/foo_n207_004.adb: No such file or directory +print vars'length gdb.in:4: Error in sourced command file: Bad GNAT array descriptor bounds ... -- You are receiving this mail because: You are on the CC list for the bug.
next prev parent reply other threads:[~2024-04-18 7:54 UTC|newest] Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top 2024-04-17 11:05 [Bug ada/31648] New: " vries at gcc dot gnu.org 2024-04-18 7:37 ` [Bug ada/31648] " vries at gcc dot gnu.org 2024-04-18 7:39 ` vries at gcc dot gnu.org 2024-04-18 7:46 ` vries at gcc dot gnu.org 2024-04-18 7:54 ` vries at gcc dot gnu.org [this message] 2024-04-18 7:54 ` vries at gcc dot gnu.org 2024-04-18 8:00 ` vries at gcc dot gnu.org 2024-04-18 17:37 ` tromey at sourceware dot org 2024-04-18 18:12 ` tromey at sourceware dot org
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=bug-31648-4717-Ac9tGebKmG@http.sourceware.org/bugzilla/ \ --to=sourceware-bugzilla@sourceware.org \ --cc=gdb-prs@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: linkBe 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).