From: Tom de Vries via Gdb-patches <gdb-patches@sourceware.org>
To: gdb-patches@sourceware.org
Subject: [committed][gdb/testsuite] Fix gdb.base/bt-on-error-and-warning.exp with check-read1
Date: Fri, 8 Oct 2021 12:35:03 +0200 [thread overview]
Message-ID: <20211008103055.GA22642@delia.home> (raw)
Hi,
When running test-case gdb.base/bt-on-error-and-warning.exp with check-read1,
I run into:
...
(gdb) maint internal-error foobar^M
src/gdb/maint.c:82: internal-error: foobar^M
A problem internal to GDB has been detectedFAIL: \
gdb.base/bt-on-error-and-warning.exp: problem=internal-error, mode=on: \
scan for backtrace (GDB internal error)
Resyncing due to internal error.
,^M
...
The corresponding gdb_test_multiple in the test-case contains:
...
-early -re "^A problem internal to GDB has been detected,\r\n" {
incr header_lines
exp_continue
}
...
but instead this one triggers in gdb_test_multiple:
...
-re ".*A problem internal to GDB has been detected" {
fail "$message (GDB internal error)"
gdb_internal_error_resync
set result -1
}
...
Fix this by likewise shortening the regexp to before the comma.
Tested on x86_64-linux.
Committed to trunk.
Thanks,
- Tom
[gdb/testsuite] Fix gdb.base/bt-on-error-and-warning.exp with check-read1
---
gdb/testsuite/gdb.base/bt-on-error-and-warning.exp | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/gdb/testsuite/gdb.base/bt-on-error-and-warning.exp b/gdb/testsuite/gdb.base/bt-on-error-and-warning.exp
index a43a951bbd2..5ec13112f3e 100644
--- a/gdb/testsuite/gdb.base/bt-on-error-and-warning.exp
+++ b/gdb/testsuite/gdb.base/bt-on-error-and-warning.exp
@@ -70,11 +70,11 @@ proc run_test {problem_type mode} {
incr header_lines
exp_continue
}
- -early -re "^A problem internal to GDB has been detected,\r\n" {
+ -early -re "^A problem internal to GDB has been detected" {
incr header_lines
exp_continue
}
- -early -re "^further debugging may prove unreliable\\.\r\n" {
+ -early -re "^,\r\nfurther debugging may prove unreliable\\.\r\n" {
incr header_lines
exp_continue
}
reply other threads:[~2021-10-08 10:35 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=20211008103055.GA22642@delia.home \
--to=gdb-patches@sourceware.org \
--cc=tdevries@suse.de \
/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