public inbox for gdb-cvs@sourceware.org
help / color / mirror / Atom feed
From: Tom de Vries <vries@sourceware.org>
To: gdb-cvs@sourceware.org
Subject: [binutils-gdb] [gdb/testsuite] Fix gdb.threads/threadcrash.exp with glibc debuginfo
Date: Wed, 24 Apr 2024 13:36:03 +0000 (GMT)	[thread overview]
Message-ID: <20240424133603.9ED7A384B11C@sourceware.org> (raw)

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=e6a0a281a0bf93bd22247bcd1d68b303dc657845

commit e6a0a281a0bf93bd22247bcd1d68b303dc657845
Author: Tom de Vries <tdevries@suse.de>
Date:   Wed Apr 24 15:36:02 2024 +0200

    [gdb/testsuite] Fix gdb.threads/threadcrash.exp with glibc debuginfo
    
    After installing glibc debuginfo, I ran into:
    ...
    FAIL: gdb.threads/threadcrash.exp: test_live_inferior: \
      $thread_count == [llength $test_list]
    ...
    
    This happens because the clause:
    ...
            -re "^\r\n${hs}main$hs$eol" {
    ...
    which is intended to match only:
    ...
     #1  <hex> in main () at threadcrash.c:423^M
    ...
    also matches "remaining" in:
    ...
     #1  <hex> in __GI___nanosleep (requested_time=<hex>, remaining=<hex>) at \
       nanosleep.c:27^M
    ...
    
    Fix this by checking for "in main" instead.
    
    Tested on x86_64-linux.

Diff:
---
 gdb/testsuite/gdb.threads/threadcrash.exp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gdb/testsuite/gdb.threads/threadcrash.exp b/gdb/testsuite/gdb.threads/threadcrash.exp
index c72ce73fd6d..ffbfd83942c 100644
--- a/gdb/testsuite/gdb.threads/threadcrash.exp
+++ b/gdb/testsuite/gdb.threads/threadcrash.exp
@@ -74,7 +74,7 @@ proc thread_apply_all {} {
 	    lappend test_list 6
 	    exp_continue
 	}
-	-re "^\r\n${hs}main$hs$eol" {
+	-re "^\r\n${hs}in main$hs$eol" {
 	    lappend test_list 7
 	    exp_continue
 	}

                 reply	other threads:[~2024-04-24 13:36 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=20240424133603.9ED7A384B11C@sourceware.org \
    --to=vries@sourceware.org \
    --cc=gdb-cvs@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).