aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.base/bang.exp
diff options
context:
space:
mode:
authorAnton Kolesov <akolesov@synopsys.com>2013-10-09 12:58:14 +0400
committerTom Tromey <tromey@sourceware.org>2013-10-25 14:03:01 +0000
commit38095c27fb67d4828c0b55f37714fe5c8e7dd9cd (patch)
tree292441f8ff476a689dca472365b83036ba73ea9e /gdb/testsuite/gdb.base/bang.exp
parent686d4defdf4a343d4b700b8b544cd40c4f16b0d1 (diff)
downloadgdb-38095c27fb67d4828c0b55f37714fe5c8e7dd9cd.zip
gdb-38095c27fb67d4828c0b55f37714fe5c8e7dd9cd.tar.gz
gdb-38095c27fb67d4828c0b55f37714fe5c8e7dd9cd.tar.bz2
testsuite: Fix gdb.base/bang.exp for remote stubs without exit
Some remote stubs do not have a proper exit() function implementation. gdb.base/bang.exp was failing on those targets due to timeout. With this patch bang.exp uses already defined library procedures to handle this situation gracefully without breaking native targets. Tested with x86_64 (unix, native-gdbserver) and with arc-*-elf32. gdb/testsuite/ChangeLog: 2013-10-25 Anton Kolesov <Anton.Kolesov@synopsys.com> (tiny change) * gdb.base/bang.exp: Use gdb_continue_to_end to properly support remote stubs where exit() behaviour is unreliable.
Diffstat (limited to 'gdb/testsuite/gdb.base/bang.exp')
-rw-r--r--gdb/testsuite/gdb.base/bang.exp11
1 files changed, 2 insertions, 9 deletions
diff --git a/gdb/testsuite/gdb.base/bang.exp b/gdb/testsuite/gdb.base/bang.exp
index 6fd3a59..e03c718 100644
--- a/gdb/testsuite/gdb.base/bang.exp
+++ b/gdb/testsuite/gdb.base/bang.exp
@@ -26,12 +26,5 @@ if {[prepare_for_testing $testfile.exp ${testfile}! $srcfile \
# Verify that we can run the program and that it terminates normally.
-gdb_run_cmd
-gdb_expect {
- -re ".*$inferior_exited_re normally.*$gdb_prompt $" {
- pass "run program"
- }
- timeout {
- fail "run program (timeout)"
- }
-}
+runto_main
+gdb_continue_to_end "" continue 1