From: Tom de Vries Date: Wed, 24 Apr 2024 13:36:02 +0000 (+0200) Subject: [gdb/testsuite] Fix gdb.threads/threadcrash.exp with glibc debuginfo X-Git-Tag: gdb-15-branchpoint~263 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e6a0a281a0bf93bd22247bcd1d68b303dc657845;p=thirdparty%2Fbinutils-gdb.git [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 in main () at threadcrash.c:423^M ... also matches "remaining" in: ... #1 in __GI___nanosleep (requested_time=, remaining=) at \ nanosleep.c:27^M ... Fix this by checking for "in main" instead. Tested on x86_64-linux. --- 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 }