aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2023-01-25 10:00:58 -0700
committerTom Tromey <tom@tromey.com>2023-01-26 18:28:31 -0700
commitd6acf25c03f8c507e134f7438bd4360464ce111e (patch)
tree013db4cf84afd5f7202a35e3b595e89de246146d /gdb
parent306e12673e49e32f1e64d9dca7a30fe8add42e1c (diff)
downloadbinutils-d6acf25c03f8c507e134f7438bd4360464ce111e.zip
binutils-d6acf25c03f8c507e134f7438bd4360464ce111e.tar.gz
binutils-d6acf25c03f8c507e134f7438bd4360464ce111e.tar.bz2
Start gdb after building executable in mi-basics.exp
A lot of the MI tests start gdb and only then build the executable. This just seemed weird to me, so I've fixed this up. In this patch, no other cleanups are done, the startup is just moved to a more logical (to me) spot.
Diffstat (limited to 'gdb')
-rw-r--r--gdb/testsuite/gdb.mi/mi-basics.exp10
1 files changed, 5 insertions, 5 deletions
diff --git a/gdb/testsuite/gdb.mi/mi-basics.exp b/gdb/testsuite/gdb.mi/mi-basics.exp
index 086ce74..30d0da6 100644
--- a/gdb/testsuite/gdb.mi/mi-basics.exp
+++ b/gdb/testsuite/gdb.mi/mi-basics.exp
@@ -28,11 +28,6 @@
load_lib mi-support.exp
set MIFLAGS "-i=mi"
-gdb_exit
-if [mi_gdb_start separate-inferior-tty] {
- return
-}
-
standard_testfile basics.c
# This file was audited to ensure that the explicit references to
# objdir in it are safe for parallel testing. Please be sure to
@@ -49,6 +44,11 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb
# In this file we want to test if the operations needed by the following
# procedures work, so it makes no sense using them here.
+gdb_exit
+if [mi_gdb_start separate-inferior-tty] {
+ return
+}
+
# mi_delete_breakpoints
# mi_gdb_reinitialize_dir $srcdir/$subdir
# mi_gdb_load ${binfile}