diff options
author | Tom de Vries <tdevries@suse.de> | 2022-05-08 18:32:05 +0200 |
---|---|---|
committer | Tom de Vries <tdevries@suse.de> | 2022-05-08 18:32:05 +0200 |
commit | 603df41b467152a226419a8dd5949f98a746a86e (patch) | |
tree | 04e79e49bbe39b5b0cc72f5d05331843987dfb3c /gdb/rust-lang.c | |
parent | c7dad3e9f9620b1dd9b7c72523513590552993b2 (diff) | |
download | gdb-603df41b467152a226419a8dd5949f98a746a86e.zip gdb-603df41b467152a226419a8dd5949f98a746a86e.tar.gz gdb-603df41b467152a226419a8dd5949f98a746a86e.tar.bz2 |
[gdb/testsuite] Handle init errors in gdb.mi/user-selected-context-sync.exp
In OBS, on aarch64-linux, with a gdb 11.1 based package, I run into:
...
(gdb) builtin_spawn -pty^M
new-ui mi /dev/pts/5^M
New UI allocated^M
(gdb) =thread-group-added,id="i1"^M
(gdb) ERROR: MI channel failed
warning: Error detected on fd 11^M
thread 1.1^M
Unknown thread 1.1.^M
(gdb) UNRESOLVED: gdb.mi/user-selected-context-sync.exp: mode=non-stop: \
test_cli_inferior: reset selection to thread 1.1
...
with many more UNRESOLVED following.
The ERROR is a common problem, filed as
https://sourceware.org/bugzilla/show_bug.cgi?id=28561 .
But the many UNRESOLVEDs are due to not checking whether the setup as done in
the test_setup function succeeds or not.
Fix this by:
- making test_setup return an error upon failure
- handling test_setup error at the call site
- adding a "setup done" pass/fail to be turned into an unresolved
in case of error during setup.
Tested on x86_64-linux, by manually triggering the error in
mi_gdb_start_separate_mi_tty.
Diffstat (limited to 'gdb/rust-lang.c')
0 files changed, 0 insertions, 0 deletions