Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Tom de Vries <tdevries@suse.de>
To: gdb-patches@sourceware.org
Subject: [pushed] [gdb/testsuite] Fix section hole detection in gdb.tui/scroll-back.exp
Date: Tue, 13 Oct 2026 11:19:04 +0200	[thread overview]
Message-ID: <20261013091904.974045-1-tdevries@suse.de> (raw)

On openSUSE Leap 15.6, with test-case gdb.tui/scroll-back.exp I ran into:
...
(gdb) x /cx bar-1^M
0x40056f:       Cannot access memory at address 0x400571^M
(gdb) UNSUPPORTED: $exp: require no section hole between .text_1 and .text_2
...

When I wrote the command, I thought that I specified printing one byte in hex,
but actually both c and x are format modifiers, so the size defaults to 'w'.

I filed a PR (PR34740) about stricter checking of format letters.

Fix by using "/bx".

Tested on x86_64-linux.
---
 gdb/testsuite/gdb.tui/scroll-back.exp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gdb/testsuite/gdb.tui/scroll-back.exp b/gdb/testsuite/gdb.tui/scroll-back.exp
index 76eb66eafca..8db7a165852 100644
--- a/gdb/testsuite/gdb.tui/scroll-back.exp
+++ b/gdb/testsuite/gdb.tui/scroll-back.exp
@@ -51,7 +51,7 @@ set re_hole \
 	 {$hex:\s+Cannot access memory at address $hex}]
 
 set section_hole -1
-gdb_test_multiple "x /cx bar-1" "" {
+gdb_test_multiple "x /bx bar-1" "" {
     -re -wrap $re_no_hole {
 	set section_hole 0
     }

base-commit: 80b91cb32b083868945f8da8fdeb2c20b5c9f099
-- 
2.51.0


                 reply	other threads:[~2026-10-13  9:19 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=20261013091904.974045-1-tdevries@suse.de \
    --to=tdevries@suse.de \
    --cc=gdb-patches@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