aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorAndrew Burgess <aburgess@redhat.com>2023-02-13 11:19:57 +0000
committerAndrew Burgess <aburgess@redhat.com>2023-02-13 11:19:57 +0000
commit97c195191578e9a68bfbb810eea373f5f3efcb7d (patch)
treebacc3829c4a3e56349f44e1daab8f5f89c6d2feb /gdb
parent24b7e8b18ae6410e0b2445475cd21503a2c38922 (diff)
downloadgdb-97c195191578e9a68bfbb810eea373f5f3efcb7d.zip
gdb-97c195191578e9a68bfbb810eea373f5f3efcb7d.tar.gz
gdb-97c195191578e9a68bfbb810eea373f5f3efcb7d.tar.bz2
gdb/testsuite: handle differences in guile error string output
A new guile test added in commit: commit 0a9ccb9dd79384f3ba3f8cd75940e8868f3b526f Date: Mon Feb 6 13:04:16 2023 +0000 gdb: only allow one of thread or task on breakpoints or watchpoints fails for some versions of guile. It turns out that some versions of guile emit an error like this: (gdb) guile (set-breakpoint-thread! bp 1) ERROR: In procedure set-breakpoint-thread!: In procedure gdbscm_set_breakpoint_thread_x: cannot set both task and thread attributes Error while executing Scheme code. while other versions of guile emit the error like this: (gdb) guile (set-breakpoint-thread! bp 1) ERROR: In procedure set-breakpoint-thread!: ERROR: In procedure gdbscm_set_breakpoint_thread_x: cannot set both task and thread attributes Error while executing Scheme code. notice the extra 'ERROR: ' on the second line of output. This commit updates the test regexp to handle this optional 'ERROR: ' string.
Diffstat (limited to 'gdb')
-rw-r--r--gdb/testsuite/gdb.ada/tasks.exp6
1 files changed, 4 insertions, 2 deletions
diff --git a/gdb/testsuite/gdb.ada/tasks.exp b/gdb/testsuite/gdb.ada/tasks.exp
index a73a191..eb7ee5c 100644
--- a/gdb/testsuite/gdb.ada/tasks.exp
+++ b/gdb/testsuite/gdb.ada/tasks.exp
@@ -127,7 +127,8 @@ if {[allow_guile_tests]} {
gdb_test "guile (set-breakpoint-thread! bp 1)" \
[multi_line \
"ERROR: In procedure set-breakpoint-thread!:" \
- "In procedure gdbscm_set_breakpoint_thread_x: cannot set both task and thread attributes" \
+ "(ERROR: )?In procedure gdbscm_set_breakpoint_thread_x:\
+ cannot set both task and thread attributes" \
"Error while executing Scheme code."] \
"attempt to set thread, but expect an error"
@@ -138,7 +139,8 @@ if {[allow_guile_tests]} {
gdb_test "guile (set-breakpoint-task! bp 1)" \
[multi_line \
"ERROR: In procedure set-breakpoint-task!:" \
- "In procedure gdbscm_set_breakpoint_task_x: cannot set both task and thread attributes" \
+ "(ERROR: )?In procedure gdbscm_set_breakpoint_task_x:\
+ cannot set both task and thread attributes" \
"Error while executing Scheme code."] \
"attempt to set task, but expect an error"