diff options
Diffstat (limited to 'gdb/testsuite/gdb.server/ext-run.exp')
-rw-r--r-- | gdb/testsuite/gdb.server/ext-run.exp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/gdb/testsuite/gdb.server/ext-run.exp b/gdb/testsuite/gdb.server/ext-run.exp index 978e4a1..5797c80 100644 --- a/gdb/testsuite/gdb.server/ext-run.exp +++ b/gdb/testsuite/gdb.server/ext-run.exp @@ -31,7 +31,11 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } +# Start with a fresh gdb, gdb_skip_xml_test must be called while gdb +# is not running. + gdb_exit +set do_xml_test [expr ![gdb_skip_xml_test]] gdb_start gdb_load $binfile gdb_reinitialize_dir $srcdir/$subdir @@ -46,7 +50,10 @@ gdb_test "run" "Breakpoint.* main .*" "continue to main" if { [istarget *-*-linux*] } { # On Linux, gdbserver can also report the list of processes. - gdb_test "info os processes" ".*pid +user +command.*1 +root +\[/a-z\]*init.*" "get process list" + # But only if xml support is compiled in. + if { $do_xml_test } { + gdb_test "info os processes" ".*pid +user +command.*1 +root +\[/a-z\]*init.*" "get process list" + } } gdb_test "kill" "" "kill" "Kill the program being debugged.*" "y" |