[v2,14/37] GDB: testsuite: base: Don't return 0 from top-level (sed)

Message ID 20260429230432.60487-15-thiago.bauermann@linaro.org
State New
Headers
Series GDB: testsuite: Fix top-level returns |

Commit Message

Thiago Jung Bauermann April 29, 2026, 11:04 p.m. UTC
  This patch is purely the result of running:

$ sed -i 's/^    return 0/    return/' *.exp*

inside gdb/testsuite/gdb.base.

I didn't include changes made to return statements inside procedures.
---
 gdb/testsuite/gdb.base/advance.exp                        | 2 +-
 gdb/testsuite/gdb.base/asmlabel.exp                       | 2 +-
 gdb/testsuite/gdb.base/attach-pie-noexec.exp              | 4 ++--
 gdb/testsuite/gdb.base/auto-connect-native-target.exp     | 2 +-
 gdb/testsuite/gdb.base/auxv.exp                           | 2 +-
 gdb/testsuite/gdb.base/backtrace.exp                      | 2 +-
 gdb/testsuite/gdb.base/break-caller-line.exp              | 4 ++--
 gdb/testsuite/gdb.base/call-signal-resume.exp             | 4 ++--
 gdb/testsuite/gdb.base/callexit.exp                       | 2 +-
 gdb/testsuite/gdb.base/clear_non_user_bp.exp              | 2 +-
 gdb/testsuite/gdb.base/compare-sections.exp               | 2 +-
 gdb/testsuite/gdb.base/complex-parts.exp                  | 2 +-
 gdb/testsuite/gdb.base/cond-eval-mode.exp                 | 2 +-
 gdb/testsuite/gdb.base/condbreak-call-false.exp           | 2 +-
 gdb/testsuite/gdb.base/consecutive-step-over.exp          | 2 +-
 gdb/testsuite/gdb.base/corefile-exec-context.exp          | 4 ++--
 gdb/testsuite/gdb.base/corefile.exp                       | 2 +-
 gdb/testsuite/gdb.base/corefile2.exp                      | 2 +-
 gdb/testsuite/gdb.base/ctf-constvars.exp                  | 2 +-
 gdb/testsuite/gdb.base/ctf-ptype.exp                      | 2 +-
 gdb/testsuite/gdb.base/decl-before-def.exp                | 2 +-
 gdb/testsuite/gdb.base/dup-sect.exp                       | 2 +-
 gdb/testsuite/gdb.base/eh_return.exp                      | 2 +-
 gdb/testsuite/gdb.base/eu-strip-infcall.exp               | 2 +-
 gdb/testsuite/gdb.base/frameapply.exp                     | 2 +-
 gdb/testsuite/gdb.base/func-ptr.exp                       | 2 +-
 gdb/testsuite/gdb.base/gdb11530.exp                       | 2 +-
 gdb/testsuite/gdb.base/gdb1555.exp                        | 2 +-
 gdb/testsuite/gdb.base/info-locals-unused-static-var.exp  | 2 +-
 gdb/testsuite/gdb.base/info-shared.exp                    | 2 +-
 gdb/testsuite/gdb.base/info_qt.exp                        | 2 +-
 gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp      | 2 +-
 gdb/testsuite/gdb.base/interrupt.exp                      | 2 +-
 gdb/testsuite/gdb.base/label-without-address.exp          | 2 +-
 gdb/testsuite/gdb.base/list-missing-source.exp            | 2 +-
 gdb/testsuite/gdb.base/macscp.exp                         | 4 ++--
 .../gdb.base/maint-info-inline-frames-and-blocks.exp      | 2 +-
 gdb/testsuite/gdb.base/many-headers.exp                   | 2 +-
 gdb/testsuite/gdb.base/max-value-size.exp                 | 2 +-
 gdb/testsuite/gdb.base/overlays.exp                       | 2 +-
 gdb/testsuite/gdb.base/pr11022.exp                        | 2 +-
 gdb/testsuite/gdb.base/prelink.exp                        | 2 +-
 gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp  | 2 +-
 gdb/testsuite/gdb.base/print-internal-string.exp          | 2 +-
 gdb/testsuite/gdb.base/printcmds.exp                      | 2 +-
 gdb/testsuite/gdb.base/ptype-offsets-c.exp                | 2 +-
 gdb/testsuite/gdb.base/ptype-offsets.exp                  | 2 +-
 gdb/testsuite/gdb.base/reggroups.exp                      | 2 +-
 gdb/testsuite/gdb.base/rtld-step.exp                      | 2 +-
 gdb/testsuite/gdb.base/savedregs.exp                      | 2 +-
 gdb/testsuite/gdb.base/set-noassign.exp                   | 2 +-
 gdb/testsuite/gdb.base/shreloc.exp                        | 2 +-
 gdb/testsuite/gdb.base/sigaltstack.exp                    | 2 +-
 gdb/testsuite/gdb.base/sigbpt.exp                         | 2 +-
 gdb/testsuite/gdb.base/siginfo-addr.exp                   | 2 +-
 gdb/testsuite/gdb.base/siginfo-obj.exp                    | 4 ++--
 gdb/testsuite/gdb.base/siginfo-thread.exp                 | 2 +-
 gdb/testsuite/gdb.base/siginfo.exp                        | 2 +-
 gdb/testsuite/gdb.base/signull.exp                        | 2 +-
 gdb/testsuite/gdb.base/sigrepeat.exp                      | 2 +-
 gdb/testsuite/gdb.base/solib-disc.exp                     | 8 ++++----
 gdb/testsuite/gdb.base/solib-weak.exp                     | 4 ++--
 gdb/testsuite/gdb.base/source-execution.exp               | 2 +-
 gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp            | 2 +-
 gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp              | 2 +-
 gdb/testsuite/gdb.base/stack-checking.exp                 | 2 +-
 gdb/testsuite/gdb.base/stack-protector.exp                | 2 +-
 gdb/testsuite/gdb.base/structs2.exp                       | 2 +-
 gdb/testsuite/gdb.base/sym-file.exp                       | 2 +-
 gdb/testsuite/gdb.base/symlink-sourcefile.exp             | 2 +-
 gdb/testsuite/gdb.base/term.exp                           | 2 +-
 gdb/testsuite/gdb.base/type-opaque.exp                    | 2 +-
 gdb/testsuite/gdb.base/until-nodebug.exp                  | 2 +-
 gdb/testsuite/gdb.base/until.exp                          | 2 +-
 gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl        | 2 +-
 gdb/testsuite/gdb.base/unwindonsignal.exp                 | 4 ++--
 gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp          | 2 +-
 77 files changed, 88 insertions(+), 88 deletions(-)
  

Patch

diff --git a/gdb/testsuite/gdb.base/advance.exp b/gdb/testsuite/gdb.base/advance.exp
index fe05dd3a3c37..9cde2de12b48 100644
--- a/gdb/testsuite/gdb.base/advance.exp
+++ b/gdb/testsuite/gdb.base/advance.exp
@@ -20,11 +20,11 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Verify that "advance <location>" works.  (This is really just syntactic
 # sugar for "tbreak <location>; continue".)
 #
diff --git a/gdb/testsuite/gdb.base/asmlabel.exp b/gdb/testsuite/gdb.base/asmlabel.exp
index 15f3695d796c..cfda30085737 100644
--- a/gdb/testsuite/gdb.base/asmlabel.exp
+++ b/gdb/testsuite/gdb.base/asmlabel.exp
@@ -36,11 +36,11 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 set L1_bploc [gdb_get_line_number "set L1 breakpoint here" $srcfile]
 set L2_bploc [gdb_get_line_number "set L2 breakpoint here" $srcfile]
 
diff --git a/gdb/testsuite/gdb.base/attach-pie-noexec.exp b/gdb/testsuite/gdb.base/attach-pie-noexec.exp
index 54a4b0bffae7..b332a092544c 100644
--- a/gdb/testsuite/gdb.base/attach-pie-noexec.exp
+++ b/gdb/testsuite/gdb.base/attach-pie-noexec.exp
@@ -29,11 +29,11 @@  gdb_test_multiple $test $test {
 	set arch $expect_out(1,string)
 	pass $test
     }
 }
 if {![runto_main]} {
-    return 0
+    return
 }
 set test "sanity check info shared"
 gdb_test_multiple "info shared" $test {
     -re "From\[ \t\]+To(\\s+NS)?\[ \t\]+Syms Read\[ \t\]+Shared Object Library\r\n0x.*\r\n$gdb_prompt $" {
 	pass $test
@@ -44,11 +44,11 @@  gdb_test_multiple "info shared" $test {
 }
 gdb_exit
 
 if {$arch == ""} {
     untested "no architecture set"
-    return 0
+    return
 }
 
 # Start the program running and then wait for a bit, to be sure
 # that it can be attached to.
 
diff --git a/gdb/testsuite/gdb.base/auto-connect-native-target.exp b/gdb/testsuite/gdb.base/auto-connect-native-target.exp
index 4529d68e16c6..a5a95b8b5a0a 100644
--- a/gdb/testsuite/gdb.base/auto-connect-native-target.exp
+++ b/gdb/testsuite/gdb.base/auto-connect-native-target.exp
@@ -51,11 +51,11 @@  if { $topmost != "exec" } {
 }
 
 # Check which target this board connects to.  If testing with a native
 # target board, this should cause the native target to auto connect.
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Returns true if the native target is pushed on the target stack.
 # TEST is used as test message.
 
diff --git a/gdb/testsuite/gdb.base/auxv.exp b/gdb/testsuite/gdb.base/auxv.exp
index 79e897078e5d..9d32cee85522 100644
--- a/gdb/testsuite/gdb.base/auxv.exp
+++ b/gdb/testsuite/gdb.base/auxv.exp
@@ -51,11 +51,11 @@  if {$core_works} {
 	set core_works 0
     }
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 set print_core_line [gdb_get_line_number "ABORT;"]
 gdb_test "tbreak $print_core_line"
 gdb_test continue ".*ABORT;.*"
 
diff --git a/gdb/testsuite/gdb.base/backtrace.exp b/gdb/testsuite/gdb.base/backtrace.exp
index 612dd2ad6a87..7aee6b1cebc3 100644
--- a/gdb/testsuite/gdb.base/backtrace.exp
+++ b/gdb/testsuite/gdb.base/backtrace.exp
@@ -20,11 +20,11 @@  standard_testfile
 if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Run to the breakpoint at return.
 gdb_breakpoint [gdb_get_line_number "Break here."]
 gdb_continue_to_breakpoint "Break here."
diff --git a/gdb/testsuite/gdb.base/break-caller-line.exp b/gdb/testsuite/gdb.base/break-caller-line.exp
index 7fdef95cc607..c7a136a6663e 100644
--- a/gdb/testsuite/gdb.base/break-caller-line.exp
+++ b/gdb/testsuite/gdb.base/break-caller-line.exp
@@ -18,11 +18,11 @@  standard_testfile
 if { [prepare_for_testing "failed to prepare" ${testfile}] } {
     return
 }
 
 if {![runto callee]} {
-    return 0
+    return
 }
 
 set test "up"
 gdb_test_multiple $test $test {
     -re "\r\n(${::decimal})\[ \t\]+callee \\(\\);\r\n$gdb_prompt $" {
@@ -39,11 +39,11 @@  gdb_test_multiple $test $test {
     }
 }
 
 if {$notcurrent == $current} {
     untested "target arch has an instruction after call as part of the caller line"
-    return 0
+    return
 }
 
 set test "break"
 gdb_test_multiple $test $test {
     -re "\r\nBreakpoint ${::decimal} at .*, line $current\\.\r\n$gdb_prompt $" {
diff --git a/gdb/testsuite/gdb.base/call-signal-resume.exp b/gdb/testsuite/gdb.base/call-signal-resume.exp
index 8f12b1618be1..4ade8c2d245a 100644
--- a/gdb/testsuite/gdb.base/call-signal-resume.exp
+++ b/gdb/testsuite/gdb.base/call-signal-resume.exp
@@ -43,11 +43,11 @@  proc get_dummy_frame_number { } {
     }
     return ""
 }
 
 if { ![runto_main] } {
-    return 0
+    return
 }
 
 gdb_test "break stop_one" "Breakpoint \[0-9\]* at .*"
 gdb_test "continue" "Continuing.*Breakpoint \[0-9\]*, stop_one.*" \
     "continue to breakpoint at stop_one"
@@ -55,11 +55,11 @@  gdb_test "continue" "Continuing.*Breakpoint \[0-9\]*, stop_one.*" \
 # Call function (causing the program to get a signal), and see if gdb handles
 # it properly.
 if {[gdb_test "call gen_signal ()"  \
 	 "\[\r\n\]*The program being debugged was signaled.*" \
 	 "inferior function call signaled"] != 0} {
-    return 0
+    return
 }
 
 set frame_number [get_dummy_frame_number]
 if { "$frame_number" == "" } {
     fail "dummy stack frame number"
diff --git a/gdb/testsuite/gdb.base/callexit.exp b/gdb/testsuite/gdb.base/callexit.exp
index 986d225d3aad..376d1f0c14cb 100644
--- a/gdb/testsuite/gdb.base/callexit.exp
+++ b/gdb/testsuite/gdb.base/callexit.exp
@@ -22,11 +22,11 @@  standard_testfile .c
 if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } {
     return
 }
 
 if { ![runto_main] } {
-    return 0
+    return
 }
 
 # Verify set may-call-functions behavior.
 gdb_test_no_output "set may-call-functions off"
 gdb_test "call callexit()" \
diff --git a/gdb/testsuite/gdb.base/clear_non_user_bp.exp b/gdb/testsuite/gdb.base/clear_non_user_bp.exp
index ead811f68546..22e67c935cd7 100644
--- a/gdb/testsuite/gdb.base/clear_non_user_bp.exp
+++ b/gdb/testsuite/gdb.base/clear_non_user_bp.exp
@@ -44,11 +44,11 @@  standard_testfile main.c
 if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 set bp_num [get_first_maint_bp_num]
 set bp_addr [gdb_get_bp_addr $bp_num]
 
diff --git a/gdb/testsuite/gdb.base/compare-sections.exp b/gdb/testsuite/gdb.base/compare-sections.exp
index f647cc5a8491..bf6207061778 100644
--- a/gdb/testsuite/gdb.base/compare-sections.exp
+++ b/gdb/testsuite/gdb.base/compare-sections.exp
@@ -78,11 +78,11 @@  gdb_test_multiple $command $test {
     }
 }
 
 # Now get past startup code.
 if {![runto_main]} {
-    return 0
+    return
 }
 
 with_test_prefix "after run to main" {
     # Assume all targets' startup code changes some loaded variable.
     gdb_test "compare-sections" \
diff --git a/gdb/testsuite/gdb.base/complex-parts.exp b/gdb/testsuite/gdb.base/complex-parts.exp
index 56260996bdb6..b156dcb2646c 100644
--- a/gdb/testsuite/gdb.base/complex-parts.exp
+++ b/gdb/testsuite/gdb.base/complex-parts.exp
@@ -18,11 +18,11 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 set marker " Break Here. "
 gdb_breakpoint [gdb_get_line_number $marker]
 gdb_continue_to_breakpoint "breakpt" ".*[string_to_regexp $marker].*"
diff --git a/gdb/testsuite/gdb.base/cond-eval-mode.exp b/gdb/testsuite/gdb.base/cond-eval-mode.exp
index e2afc3a95939..e9463950eb54 100644
--- a/gdb/testsuite/gdb.base/cond-eval-mode.exp
+++ b/gdb/testsuite/gdb.base/cond-eval-mode.exp
@@ -28,11 +28,11 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 set test_host "set breakpoint condition-evaluation host"
 set test_auto "set breakpoint condition-evaluation auto"
 set test_target "set breakpoint condition-evaluation target"
diff --git a/gdb/testsuite/gdb.base/condbreak-call-false.exp b/gdb/testsuite/gdb.base/condbreak-call-false.exp
index 32113e3b9501..0a240601b348 100644
--- a/gdb/testsuite/gdb.base/condbreak-call-false.exp
+++ b/gdb/testsuite/gdb.base/condbreak-call-false.exp
@@ -21,11 +21,11 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 gdb_test "break foo if zero()" "Breakpoint .*"
 gdb_test "break bar" "Breakpoint .*"
 
diff --git a/gdb/testsuite/gdb.base/consecutive-step-over.exp b/gdb/testsuite/gdb.base/consecutive-step-over.exp
index d7efec8f418d..12ef2dcc4d4f 100644
--- a/gdb/testsuite/gdb.base/consecutive-step-over.exp
+++ b/gdb/testsuite/gdb.base/consecutive-step-over.exp
@@ -23,11 +23,11 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Make sure the target doesn't hide the breakpoint hits (that don't
 # cause a user visible stop) from GDB.
 gdb_test_no_output "set breakpoint condition-evaluation host"
diff --git a/gdb/testsuite/gdb.base/corefile-exec-context.exp b/gdb/testsuite/gdb.base/corefile-exec-context.exp
index bf935a795e7d..8c342171cecf 100644
--- a/gdb/testsuite/gdb.base/corefile-exec-context.exp
+++ b/gdb/testsuite/gdb.base/corefile-exec-context.exp
@@ -42,11 +42,11 @@  if { $binfile_len <= 80 } {
 # Generate a core file, this time the inferior has no additional
 # arguments.
 set corefile [core_find $binfile {}]
 if {$corefile == ""} {
     untested "unable to create corefile"
-    return 0
+    return
 }
 set corefile_1 "$binfile.1.core"
 remote_exec build "mv $corefile $corefile_1"
 
 # Load the core file and confirm that the full executable name is
@@ -71,11 +71,11 @@  gdb_test_multiple "core-file $corefile_1" "load core file no args" {
 # Generate a core file, this time pass some arguments to the inferior.
 set args "aaaaa bbbbb ccccc ddddd e\\\\ e\\\\ e\\\\ e\\\\ e"
 set corefile [core_find $binfile {} $args]
 if {$corefile == ""} {
     untested "unable to create corefile"
-    return 0
+    return
 }
 set corefile_2 "$binfile.2.core"
 remote_exec build "mv $corefile $corefile_2"
 
 # Load the core file and confirm that the full executable name and
diff --git a/gdb/testsuite/gdb.base/corefile.exp b/gdb/testsuite/gdb.base/corefile.exp
index 31249355353f..4f36dc58b29c 100644
--- a/gdb/testsuite/gdb.base/corefile.exp
+++ b/gdb/testsuite/gdb.base/corefile.exp
@@ -30,11 +30,11 @@  if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} {
 # required for GDB to find mmap'd data in the "accessing read-only
 # mmapped data in core file" test.
 set corefile [core_find $binfile {}]
 if {$corefile == ""} {
     untested "unable to create or find corefile"
-    return 0
+    return
 }
 
 # Start GDB with COREFILE passed as a command line argument.  COREOPT
 # is prefixed before COREFILE and is the command line flag to specify
 # the corefile, i.e. one of '--core=', '-core=', '-c '.
diff --git a/gdb/testsuite/gdb.base/corefile2.exp b/gdb/testsuite/gdb.base/corefile2.exp
index 805e08973f6b..d98e8b0bd301 100644
--- a/gdb/testsuite/gdb.base/corefile2.exp
+++ b/gdb/testsuite/gdb.base/corefile2.exp
@@ -39,11 +39,11 @@  if {[build_executable $testfile.exp $testfile $srcfile debug] == -1} {
 }
 
 set corefile [core_find $binfile {}]
 if {$corefile == ""} {
     untested "unable to create or find corefile"
-    return 0
+    return
 }
 
 gdb_start
 gdb_reinitialize_dir $srcdir/$subdir
 gdb_load ${binfile}
diff --git a/gdb/testsuite/gdb.base/ctf-constvars.exp b/gdb/testsuite/gdb.base/ctf-constvars.exp
index 0fc59f226e45..9a98aaebe68a 100644
--- a/gdb/testsuite/gdb.base/ctf-constvars.exp
+++ b/gdb/testsuite/gdb.base/ctf-constvars.exp
@@ -34,11 +34,11 @@  lappend opts additional_flags=-gctf
 lappend opts ldflags=-Wl,--ctf-variables
 lappend opts nowarnings
 
 if { [build_executable "failed to prepare" ${testfile} \
 	  [list $srcfile] $opts] } {
-    return 0
+    return
 }
 
 clean_restart
 gdb_test_no_output "set always-read-ctf on"
 gdb_load $binfile
diff --git a/gdb/testsuite/gdb.base/ctf-ptype.exp b/gdb/testsuite/gdb.base/ctf-ptype.exp
index d3c3b46140c5..aabe3c9187d5 100644
--- a/gdb/testsuite/gdb.base/ctf-ptype.exp
+++ b/gdb/testsuite/gdb.base/ctf-ptype.exp
@@ -28,11 +28,11 @@  lappend opts additional_flags=-gctf
 lappend opts ldflags=-Wl,--ctf-variables
 lappend opts nowarnings
 
 if { [prepare_for_testing "failed to prepare" ${testfile} \
 	  [list $srcfile] $opts] } {
-    return 0
+    return
 }
 
 clean_restart
 gdb_test_no_output "set always-read-ctf on"
 gdb_load $binfile
diff --git a/gdb/testsuite/gdb.base/decl-before-def.exp b/gdb/testsuite/gdb.base/decl-before-def.exp
index 66083d2aa710..396fd31bb850 100644
--- a/gdb/testsuite/gdb.base/decl-before-def.exp
+++ b/gdb/testsuite/gdb.base/decl-before-def.exp
@@ -24,9 +24,9 @@  if {[prepare_for_testing "failed to prepare" $testfile $sources]} {
 gdb_test "maint expand-symtabs"
 
 gdb_test "p a" { = \{1, 2\}} "no running process: p a"
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 gdb_test "p a" { = \{1, 2\}} "running process: p a"
diff --git a/gdb/testsuite/gdb.base/dup-sect.exp b/gdb/testsuite/gdb.base/dup-sect.exp
index ef9ba340ae24..b20c0e8ca731 100644
--- a/gdb/testsuite/gdb.base/dup-sect.exp
+++ b/gdb/testsuite/gdb.base/dup-sect.exp
@@ -27,11 +27,11 @@ 
 if {![istarget *-*-linux*]
     && ![istarget *-*-gnu*]
     && ![istarget *-*-elf*]
     && ![istarget arm*-*-eabi*]
     && ![istarget powerpc-*-eabi*]} {
-    return 0
+    return
 }
 
 standard_testfile .S
 set srcmainfile start.c
 set executable ${testfile}
diff --git a/gdb/testsuite/gdb.base/eh_return.exp b/gdb/testsuite/gdb.base/eh_return.exp
index c6f1d7375c58..5a32ab0d2b89 100644
--- a/gdb/testsuite/gdb.base/eh_return.exp
+++ b/gdb/testsuite/gdb.base/eh_return.exp
@@ -66,11 +66,11 @@  gdb_test_multiple "disassemble eh2" "" {
 	pass $gdb_test_name
     }
 }
 
 if { $address == -1 } {
-    return 0
+    return
 }
 
 clean_restart $testfile
 
 gdb_assert [gdb_breakpoint "*$address" no-message] "set breakpoint on address"
diff --git a/gdb/testsuite/gdb.base/eu-strip-infcall.exp b/gdb/testsuite/gdb.base/eu-strip-infcall.exp
index 73df0e5650bb..6cc079e81688 100644
--- a/gdb/testsuite/gdb.base/eu-strip-infcall.exp
+++ b/gdb/testsuite/gdb.base/eu-strip-infcall.exp
@@ -21,11 +21,11 @@  if {[build_executable ${testfile}.exp $testfile] == -1} {
 
 set test "eu-strip"
 set status [remote_exec build "eu-strip -f ${binfile}.debug $binfile"]
 if {[lindex $status 0] != 0} {
     untested "failed to compile"
-    return 0
+    return
 }
 
 clean_restart $testfile
 
 if {![runto_main]} {
diff --git a/gdb/testsuite/gdb.base/frameapply.exp b/gdb/testsuite/gdb.base/frameapply.exp
index 7525ba5085c5..2ca2ce0461ff 100644
--- a/gdb/testsuite/gdb.base/frameapply.exp
+++ b/gdb/testsuite/gdb.base/frameapply.exp
@@ -23,11 +23,11 @@  standard_testfile
 if { [prepare_for_testing "failed to prepare" ${testfile}] } {
     return
 }
 
 if {![runto setup_done]} {
-    return 0
+    return
 }
 
 set any "\[^\r\n\]*"
 set ws "\[ \t\]\+"
 set number "\[0-9]\+"
diff --git a/gdb/testsuite/gdb.base/func-ptr.exp b/gdb/testsuite/gdb.base/func-ptr.exp
index 0f656d127807..ba2807704aba 100644
--- a/gdb/testsuite/gdb.base/func-ptr.exp
+++ b/gdb/testsuite/gdb.base/func-ptr.exp
@@ -20,10 +20,10 @@ 
 if { [prepare_for_testing "failed to prepare" "func-ptr" {func-ptr.c} {debug}] } {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # This would put gdb into an infinite loop.
 gdb_test "print pbar->baz" "Attempt to extract .*"
diff --git a/gdb/testsuite/gdb.base/gdb11530.exp b/gdb/testsuite/gdb.base/gdb11530.exp
index fb293b986c7d..678b1184d30c 100644
--- a/gdb/testsuite/gdb.base/gdb11530.exp
+++ b/gdb/testsuite/gdb.base/gdb11530.exp
@@ -21,11 +21,11 @@ 
 standard_testfile
 
 # Unnamed union is a GNU extension, thus we restrict the test
 # to gcc compiler.
 if { ![test_compiler_info gcc*] } {
-    return 0
+    return
 }
 
 if { [prepare_for_testing "failed to prepare" $testfile $testfile.c {debug}] } {
     return
 }
diff --git a/gdb/testsuite/gdb.base/gdb1555.exp b/gdb/testsuite/gdb.base/gdb1555.exp
index 9b463b75d541..6402a8f4e291 100644
--- a/gdb/testsuite/gdb.base/gdb1555.exp
+++ b/gdb/testsuite/gdb.base/gdb1555.exp
@@ -38,11 +38,11 @@  if { [prepare_for_testing "prepare" $testfile $execsrc\
 }
 
 gdb_load_shlib $libobj
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # PR/1555 (was shlib 1280)
 set name "Step into shared lib function"
 gdb_test_multiple "s" $name \
diff --git a/gdb/testsuite/gdb.base/info-locals-unused-static-var.exp b/gdb/testsuite/gdb.base/info-locals-unused-static-var.exp
index a1fffc51ea2b..8834b73fdf6d 100644
--- a/gdb/testsuite/gdb.base/info-locals-unused-static-var.exp
+++ b/gdb/testsuite/gdb.base/info-locals-unused-static-var.exp
@@ -31,9 +31,9 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 gdb_test "info locals" "\r\nb = .*"
diff --git a/gdb/testsuite/gdb.base/info-shared.exp b/gdb/testsuite/gdb.base/info-shared.exp
index 41a47a30d7d6..993e64f64a27 100644
--- a/gdb/testsuite/gdb.base/info-shared.exp
+++ b/gdb/testsuite/gdb.base/info-shared.exp
@@ -83,11 +83,11 @@  proc check_info_shared { test expect1 expect2 } {
 check_info_shared "info sharedlibrary before running" 0 0
 
 # Start the inferior, and check neither of the libraries are loaded at
 # the start.
 if {![runto_main]} {
-    return 0
+    return
 }
 check_info_shared "info sharedlibrary #1" 0 0
 
 # Set up breakpoints.
 gdb_breakpoint "stop"
diff --git a/gdb/testsuite/gdb.base/info_qt.exp b/gdb/testsuite/gdb.base/info_qt.exp
index 40cd9547bae8..6ae4fc3bf7ac 100644
--- a/gdb/testsuite/gdb.base/info_qt.exp
+++ b/gdb/testsuite/gdb.base/info_qt.exp
@@ -26,11 +26,11 @@  standard_testfile
 if { [prepare_for_testing "failed to prepare" ${testfile}] } {
     return
 }
 
 if {![runto setup_done]} {
-    return 0
+    return
 }
 
 set any "\[^\r\n\]*"
 set ws "\[ \t\]\+"
 set number "\[0-9]\+"
diff --git a/gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp b/gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp
index 4bda78dd27d6..3a378cd69601 100644
--- a/gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp
+++ b/gdb/testsuite/gdb.base/inline-frame-cycle-unwind.exp
@@ -56,11 +56,11 @@  require allow_python_tests
 if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 set pyfile [gdb_remote_download host ${srcdir}/${subdir}/${testfile}.py]
 
 # Run to the breakpoint where we will carry out the test.
diff --git a/gdb/testsuite/gdb.base/interrupt.exp b/gdb/testsuite/gdb.base/interrupt.exp
index 44a27434bc2b..884a66a0d561 100644
--- a/gdb/testsuite/gdb.base/interrupt.exp
+++ b/gdb/testsuite/gdb.base/interrupt.exp
@@ -34,11 +34,11 @@  if {[build_executable $testfile.exp $testfile $srcfile $options] == -1} {
 
 gdb_start
 
 
 if {![file exists $binfile]} {
-    return 0
+    return
 } else {
     gdb_reinitialize_dir $srcdir/$subdir
     gdb_load $binfile
     # Hope this is unix :-)
     gdb_test "shell stty intr '^C'" ".*" \
diff --git a/gdb/testsuite/gdb.base/label-without-address.exp b/gdb/testsuite/gdb.base/label-without-address.exp
index 7796de94c078..1a6a5f611426 100644
--- a/gdb/testsuite/gdb.base/label-without-address.exp
+++ b/gdb/testsuite/gdb.base/label-without-address.exp
@@ -18,11 +18,11 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 set supported 0
 gdb_test_multiple "l main:L1" "" {
     -wrap -re "No label \"L1\" defined in function \"main\"\." {
diff --git a/gdb/testsuite/gdb.base/list-missing-source.exp b/gdb/testsuite/gdb.base/list-missing-source.exp
index fb78c85ffb08..b5b1919073fd 100644
--- a/gdb/testsuite/gdb.base/list-missing-source.exp
+++ b/gdb/testsuite/gdb.base/list-missing-source.exp
@@ -44,11 +44,11 @@  remote_file host delete $srcfile
 
 # Now start GDB, run to main and try to list the source.
 clean_restart $testfile
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 gdb_test "list" "1\[ \t\]+in\[ \t\]+$srcfile"
 
 gdb_test "info source" \
diff --git a/gdb/testsuite/gdb.base/macscp.exp b/gdb/testsuite/gdb.base/macscp.exp
index 44debe1e7f87..e40bfb633378 100644
--- a/gdb/testsuite/gdb.base/macscp.exp
+++ b/gdb/testsuite/gdb.base/macscp.exp
@@ -203,11 +203,11 @@  gdb_test_multiple "info source" "test macro information"  {
 	warning "couldn't check macro support (no valid response)."
     }
 }
 if {$macro_support == 0} {
     unsupported "skipping test because debug information does not include macro information."
-    return 0
+    return
 }
 
 list_and_check_macro main WHERE {macscp1.c {before macscp1_3}}
 list_and_check_macro macscp2_2 WHERE {macscp2.h macscp1.c {before macscp2_2}}
 list_and_check_macro macscp3_2 WHERE {macscp3.h macscp1.c {before macscp3_2}}
@@ -332,11 +332,11 @@  proc maybe_kfail { func test_name } {
     }
 }
 
 # Start the program running.
 if {! [runto_main]} {
-    return 0
+    return
 }
 
 # Set a breakpoint on each of the functions.
 foreach func_entry $funcs {
     set func [lindex $func_entry 0]
diff --git a/gdb/testsuite/gdb.base/maint-info-inline-frames-and-blocks.exp b/gdb/testsuite/gdb.base/maint-info-inline-frames-and-blocks.exp
index b123162d6e5b..f6e4c27e4581 100644
--- a/gdb/testsuite/gdb.base/maint-info-inline-frames-and-blocks.exp
+++ b/gdb/testsuite/gdb.base/maint-info-inline-frames-and-blocks.exp
@@ -22,11 +22,11 @@  if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \
 	  {debug nopie}]} {
     return
 }
 
 if {![runto normal_func]} {
-    return 0
+    return
 }
 
 # Make a pattern to match 'maint info blocks' output.  ARGS is the
 # list of function names we expect to see.  If the function name
 # starts with 'inline_func' then we expect to see an inline block,
diff --git a/gdb/testsuite/gdb.base/many-headers.exp b/gdb/testsuite/gdb.base/many-headers.exp
index 6b13db61e740..049c601cf675 100644
--- a/gdb/testsuite/gdb.base/many-headers.exp
+++ b/gdb/testsuite/gdb.base/many-headers.exp
@@ -32,11 +32,11 @@  if {[build_executable "failed to prepare" $testfile $srcfile debug]} {
 
 # Generate core file.
 set corefile [core_find $binfile]
 if {$corefile == ""} {
     untested "unable to create or find corefile"
-    return 0
+    return
 }
 
 # Limit is in kb, so this is 4MB.
 set stack_limit 4096
 
diff --git a/gdb/testsuite/gdb.base/max-value-size.exp b/gdb/testsuite/gdb.base/max-value-size.exp
index ba5266401ee8..ddd38d84004e 100644
--- a/gdb/testsuite/gdb.base/max-value-size.exp
+++ b/gdb/testsuite/gdb.base/max-value-size.exp
@@ -18,11 +18,11 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Run "show max-value-size" and return the interesting bit of the
 # result.  This is either the maximum size in bytes, or the string
 # "unlimited".
diff --git a/gdb/testsuite/gdb.base/overlays.exp b/gdb/testsuite/gdb.base/overlays.exp
index 3f584ee83c3a..1cb452b77142 100644
--- a/gdb/testsuite/gdb.base/overlays.exp
+++ b/gdb/testsuite/gdb.base/overlays.exp
@@ -43,11 +43,11 @@  gdb_load ${binfile}
 #
 # set it up at a breakpoint so we can play with the variable values
 #
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # couple of convenience variables
 set fptrcast [string_to_regexp "{int (int)}"]
 set iptrcast [string_to_regexp "(int *)"]
diff --git a/gdb/testsuite/gdb.base/pr11022.exp b/gdb/testsuite/gdb.base/pr11022.exp
index 524d6901c94a..4d85a8ad28a2 100644
--- a/gdb/testsuite/gdb.base/pr11022.exp
+++ b/gdb/testsuite/gdb.base/pr11022.exp
@@ -20,11 +20,11 @@  standard_testfile .c
 if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 gdb_test "break [gdb_get_line_number "break here"]" \
 	".*Breakpoint.* at .*" \
 	"set breakpoint"
diff --git a/gdb/testsuite/gdb.base/prelink.exp b/gdb/testsuite/gdb.base/prelink.exp
index 4f18af4739c2..e05bc55d6070 100644
--- a/gdb/testsuite/gdb.base/prelink.exp
+++ b/gdb/testsuite/gdb.base/prelink.exp
@@ -79,11 +79,11 @@  if { $found == 0 } {
 remote_file build delete [file join $coredir coremmap.data]
 remote_exec build "rmdir $coredir"
 
 if { $found == 0  } {
     warning "can't generate a core file - prelink tests suppressed - check ulimit -c"
-    return 0
+    return
 }
 
 # Relink $libfile to a different address.
 if {![prelink_yes $prelink_args]} {
     return
diff --git a/gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp b/gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp
index c3e9fdbc6b9e..9f16d5db42c9 100644
--- a/gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp
+++ b/gdb/testsuite/gdb.base/premature-dummy-frame-removal.exp
@@ -41,11 +41,11 @@  require allow_python_tests
 if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 set pyfile [gdb_remote_download host ${srcdir}/${subdir}/${testfile}.py]
 gdb_test_no_output "source ${pyfile}" "load python file"
 
diff --git a/gdb/testsuite/gdb.base/print-internal-string.exp b/gdb/testsuite/gdb.base/print-internal-string.exp
index 7ebf8ed9b4d4..d3d694480955 100644
--- a/gdb/testsuite/gdb.base/print-internal-string.exp
+++ b/gdb/testsuite/gdb.base/print-internal-string.exp
@@ -22,11 +22,11 @@  standard_testfile
 if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 if {[allow_python_tests]} {
     # The $_as_string convenience function is implemented in Python.
     gdb_test {printf "%s\n", $_as_string("aabbcc")} "\"aabbcc\""
diff --git a/gdb/testsuite/gdb.base/printcmds.exp b/gdb/testsuite/gdb.base/printcmds.exp
index 631cfd891fcf..0be8f170d19f 100644
--- a/gdb/testsuite/gdb.base/printcmds.exp
+++ b/gdb/testsuite/gdb.base/printcmds.exp
@@ -1211,11 +1211,11 @@  if { [test_compiler_info "armcc-*"] } {
 gdb_test "p ctable1\[120\]" "120 'x'" "p ctable1\[120\] #1"
 
 gdb_load ${binfile}
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # With a running target, printf convenience vars should of course work.
 test_printf_convenience_var "with target"
 
diff --git a/gdb/testsuite/gdb.base/ptype-offsets-c.exp b/gdb/testsuite/gdb.base/ptype-offsets-c.exp
index fd88514f5f6b..9bee7b3f65b9 100644
--- a/gdb/testsuite/gdb.base/ptype-offsets-c.exp
+++ b/gdb/testsuite/gdb.base/ptype-offsets-c.exp
@@ -24,11 +24,11 @@  standard_testfile .c
 
 # Test only works on LP64 targets.  That's how we guarantee that the
 # expected holes will be present in the struct.
 if { ![is_lp64_target] } {
     untested "test work only on lp64 targets"
-    return 0
+    return
 }
 
 if { [prepare_for_testing "failed to prepare" $testfile $srcfile] } {
     return
 }
diff --git a/gdb/testsuite/gdb.base/ptype-offsets.exp b/gdb/testsuite/gdb.base/ptype-offsets.exp
index 56dca939fb33..bfee676e112f 100644
--- a/gdb/testsuite/gdb.base/ptype-offsets.exp
+++ b/gdb/testsuite/gdb.base/ptype-offsets.exp
@@ -22,11 +22,11 @@  standard_testfile .cc
 
 # Test only works on LP64 targets.  That's how we guarantee that the
 # expected holes will be present in the struct.
 if { ![is_lp64_target] } {
     untested "test work only on lp64 targets"
-    return 0
+    return
 }
 
 if { [prepare_for_testing "failed to prepare" $testfile $srcfile \
 	  { debug c++ }] } {
     return
diff --git a/gdb/testsuite/gdb.base/reggroups.exp b/gdb/testsuite/gdb.base/reggroups.exp
index f3866ec51cf4..2ff8d0940998 100644
--- a/gdb/testsuite/gdb.base/reggroups.exp
+++ b/gdb/testsuite/gdb.base/reggroups.exp
@@ -22,11 +22,11 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 set invalid_register_re "Invalid register \[^\r\n\]*"
 
 # Fetch all reggroups from 'maint print reggroups'.
diff --git a/gdb/testsuite/gdb.base/rtld-step.exp b/gdb/testsuite/gdb.base/rtld-step.exp
index 57f878dfb395..12e1cabc44db 100644
--- a/gdb/testsuite/gdb.base/rtld-step.exp
+++ b/gdb/testsuite/gdb.base/rtld-step.exp
@@ -119,11 +119,11 @@  if { [gdb_compile ${srcfile_main} ${binfile_main} executable $main_flags] != ""
 
 clean_restart
 gdb_load $binfile_main
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Running the command 'info sharedlibrary' should output a path to
 # the pretend/fake RTLD along with the address range.  Check that
 # this path is present and, if so, extract the address range.
diff --git a/gdb/testsuite/gdb.base/savedregs.exp b/gdb/testsuite/gdb.base/savedregs.exp
index 35dc10acae19..985500bb62f4 100644
--- a/gdb/testsuite/gdb.base/savedregs.exp
+++ b/gdb/testsuite/gdb.base/savedregs.exp
@@ -33,11 +33,11 @@  if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } {
     return
 }
 
 # Advance to main
 if {![runto_main]} {
-    return 0
+    return
 }
 
 proc process_saved_regs { current inner outer } {
     global gdb_prompt
     global expect_out
diff --git a/gdb/testsuite/gdb.base/set-noassign.exp b/gdb/testsuite/gdb.base/set-noassign.exp
index 0f3b843cd1fe..621769ea9c30 100644
--- a/gdb/testsuite/gdb.base/set-noassign.exp
+++ b/gdb/testsuite/gdb.base/set-noassign.exp
@@ -17,11 +17,11 @@ 
 if { [prepare_for_testing "failed to prepare" "set-noassign" start.c {debug nowarnings}] } {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Verify that set command without assignment emits a warning.
 #
 gdb_test "set language ada" ".*"
diff --git a/gdb/testsuite/gdb.base/shreloc.exp b/gdb/testsuite/gdb.base/shreloc.exp
index 5e3b60b27ee6..e0efd61bcdf9 100644
--- a/gdb/testsuite/gdb.base/shreloc.exp
+++ b/gdb/testsuite/gdb.base/shreloc.exp
@@ -67,11 +67,11 @@  if { [prepare_for_testing "prepare" $testfile $srcfile $exec_opts] != 0} {
 gdb_load_shlib $lib1_sl
 gdb_load_shlib $lib2_sl
 
 # Load up the shared objects
 if {![runto_main]} {
-    return 0
+    return
 }
 
 #
 # Check debugging symbol relocations
 #
diff --git a/gdb/testsuite/gdb.base/sigaltstack.exp b/gdb/testsuite/gdb.base/sigaltstack.exp
index 354643f237a8..c9105342fa29 100644
--- a/gdb/testsuite/gdb.base/sigaltstack.exp
+++ b/gdb/testsuite/gdb.base/sigaltstack.exp
@@ -36,11 +36,11 @@  gdb_test "handle SIGALRM print pass nostop"
 gdb_test "handle SIGVTALRM print pass nostop"
 gdb_test "handle SIGPROF print pass nostop"
 
 # Advance to main
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Stop in handle, when at the inner most level
 gdb_test "break catcher if level == INNER"
 gdb_test "continue" ".* catcher .*" "continue to catch"
diff --git a/gdb/testsuite/gdb.base/sigbpt.exp b/gdb/testsuite/gdb.base/sigbpt.exp
index c3f17e0e9707..8237b555d46e 100644
--- a/gdb/testsuite/gdb.base/sigbpt.exp
+++ b/gdb/testsuite/gdb.base/sigbpt.exp
@@ -40,11 +40,11 @@  if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
 #
 # Run to `main' where we begin our tests.
 #
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # If we can examine what's at memory address 0, it is possible that we
 # could also execute it.  This could probably make us run away,
 # executing random code, which could have all sorts of ill effects,
diff --git a/gdb/testsuite/gdb.base/siginfo-addr.exp b/gdb/testsuite/gdb.base/siginfo-addr.exp
index 93ce7a227909..a33d9bbe4999 100644
--- a/gdb/testsuite/gdb.base/siginfo-addr.exp
+++ b/gdb/testsuite/gdb.base/siginfo-addr.exp
@@ -30,11 +30,11 @@  if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
 
 gdb_test "display/i \$pc"
 
 # Advance to main
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Run to the signal.
 gdb_test "continue" ".*Program received signal SIGSEGV.*" "continue to signal"
 
diff --git a/gdb/testsuite/gdb.base/siginfo-obj.exp b/gdb/testsuite/gdb.base/siginfo-obj.exp
index daf160bc162b..a94bf0e33bae 100644
--- a/gdb/testsuite/gdb.base/siginfo-obj.exp
+++ b/gdb/testsuite/gdb.base/siginfo-obj.exp
@@ -32,11 +32,11 @@  if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 # Advance to main
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Run to the signal.
 gdb_test "continue" ".*Program received signal SIGSEGV.*" \
 	 "continue to signal, 1st"
@@ -92,11 +92,11 @@  with_test_prefix "validate siginfo fields" {
 # Again, but this time, patch si_addr and check that the inferior sees
 # the changed value.
 
 # Advance to main
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Run to the signal.
 gdb_test "continue" ".*Program received signal SIGSEGV.*" \
 	 "continue to signal, 2nd"
diff --git a/gdb/testsuite/gdb.base/siginfo-thread.exp b/gdb/testsuite/gdb.base/siginfo-thread.exp
index 14f4ac06141b..40004234138e 100644
--- a/gdb/testsuite/gdb.base/siginfo-thread.exp
+++ b/gdb/testsuite/gdb.base/siginfo-thread.exp
@@ -26,11 +26,11 @@  if { [prepare_for_testing "prepare" $testfile $srcfile {debug pthreads}] != 0 }
     return
 }
 
 # Advance to main
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Run to the signal.
 gdb_test "continue" "Thread .* received signal SIGSEGV.*" "continue to signal"
 
diff --git a/gdb/testsuite/gdb.base/siginfo.exp b/gdb/testsuite/gdb.base/siginfo.exp
index f5a00220f12a..21de03ed3f14 100644
--- a/gdb/testsuite/gdb.base/siginfo.exp
+++ b/gdb/testsuite/gdb.base/siginfo.exp
@@ -34,11 +34,11 @@  if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
 
 gdb_test "display/i \$pc"
 
 # Advance to main
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Pass all the alarms straight through (but verbosely)
 # gdb_test "handle SIGALRM print pass nostop"
 # gdb_test "handle SIGVTALRM print pass nostop"
diff --git a/gdb/testsuite/gdb.base/signull.exp b/gdb/testsuite/gdb.base/signull.exp
index 6927dac2fafc..93cc5a0301b3 100644
--- a/gdb/testsuite/gdb.base/signull.exp
+++ b/gdb/testsuite/gdb.base/signull.exp
@@ -39,11 +39,11 @@  if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } {
 #
 # Run to `main' where we begin our tests.
 #
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # If we can examine what's at memory address 0, it is possible that we
 # could also execute it.  This could probably make us run away,
 # executing random code, which could have all sorts of ill effects,
diff --git a/gdb/testsuite/gdb.base/sigrepeat.exp b/gdb/testsuite/gdb.base/sigrepeat.exp
index f14030b6f91d..d48aee2ff507 100644
--- a/gdb/testsuite/gdb.base/sigrepeat.exp
+++ b/gdb/testsuite/gdb.base/sigrepeat.exp
@@ -28,11 +28,11 @@  if { [prepare_for_testing "prepare" $testfile $srcfile] != 0 } {
     return
 }
 
 # Advance to main
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Run to the signal handler wait loop.
 set infinite_loop [gdb_get_line_number {infinite loop}]
 gdb_test "advance $infinite_loop" ".*" "advance to infinite loop"
diff --git a/gdb/testsuite/gdb.base/solib-disc.exp b/gdb/testsuite/gdb.base/solib-disc.exp
index a9b2bd471eea..6fc5bfee0083 100644
--- a/gdb/testsuite/gdb.base/solib-disc.exp
+++ b/gdb/testsuite/gdb.base/solib-disc.exp
@@ -18,11 +18,11 @@ 
 require allow_shlib_tests
 
 set gdbserver_reconnect_p 1
 if { [info proc gdb_reconnect] == "" } {
     unsupported "requires gdbserver reconnect"
-    return 0
+    return
 }
 
 set testfile solib-disc
 set libfile so-disc-shr
 set srcfile ${testfile}.c
@@ -48,11 +48,11 @@  if { [prepare_for_testing "prepare" $testfile $execsrc $exec_opts] != 0 } {
 }
 
 gdb_load_shlib $libobj
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 gdb_test_no_output "set stop-on-solib-events 1"
 
 gdb_test "continue" "Stopped due to shared library event.*" "continue to load"
@@ -69,11 +69,11 @@  gdb_test_multiple "print/x \$pc" $msg {
 gdb_test "disconnect" "Ending remote debugging\\." "disconnect after load"
 if { [gdb_reconnect] == 0 } {
     pass "reconnect after load"
 } else {
     fail "reconnect after load"
-    return 0
+    return
 }
 
 gdb_test "print/x \$pc" "${::valnum_re} = $saved_pc" "check \$pc after load"
 
 
@@ -91,9 +91,9 @@  gdb_test_multiple "print/x \$pc" $msg {
 gdb_test "disconnect" "Ending remote debugging\\." "disconnect after unload"
 if { [gdb_reconnect] == 0 } {
     pass "reconnect after unload"
 } else {
     fail "reconnect after unload"
-    return 0
+    return
 }
 
 gdb_test "print/x \$pc" "${::valnum_re} = $saved_pc" "check \$pc after unload"
diff --git a/gdb/testsuite/gdb.base/solib-weak.exp b/gdb/testsuite/gdb.base/solib-weak.exp
index 449d468603fe..319100e4a552 100644
--- a/gdb/testsuite/gdb.base/solib-weak.exp
+++ b/gdb/testsuite/gdb.base/solib-weak.exp
@@ -21,16 +21,16 @@  require allow_shlib_tests
 
 # These targets have shared libraries, but weak symbols are not meaningful.
 if {([istarget *-*-mingw*]
      || [istarget *-*-cygwin*]
      || [istarget *-*-pe*])} {
-    return 0
+    return
 }
 
 # This test uses GCC-specific syntax.
 if {![test_compiler_info "gcc-*"]} {
-    return 0
+    return
 }
 
 proc do_test { lib1opts lib2opts lib1first } {
     global srcdir subdir
 
diff --git a/gdb/testsuite/gdb.base/source-execution.exp b/gdb/testsuite/gdb.base/source-execution.exp
index a16535e97e4c..9c5b4d611498 100644
--- a/gdb/testsuite/gdb.base/source-execution.exp
+++ b/gdb/testsuite/gdb.base/source-execution.exp
@@ -22,11 +22,11 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 gdb_test "source ${srcdir}/${subdir}/source-execution.gdb" \
     "func2.*func3.*" \
     "source source-execution.gdb"
diff --git a/gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp b/gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp
index 6b299b3bc05a..be2150450485 100644
--- a/gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp
+++ b/gdb/testsuite/gdb.base/sss-bp-on-user-bp-2.exp
@@ -40,11 +40,11 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 delete_breakpoints
 
 # With the all-stop RSP, we can't talk to the target while it's
diff --git a/gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp b/gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp
index 042caf6c27bb..0bc6ff83fe87 100644
--- a/gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp
+++ b/gdb/testsuite/gdb.base/sss-bp-on-user-bp.exp
@@ -23,11 +23,11 @@  set executable ${testfile}
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 gdb_breakpoint [gdb_get_line_number "set foo break here"]
 gdb_continue_to_breakpoint "first breakpoint" ".* set foo break here .*"
 
diff --git a/gdb/testsuite/gdb.base/stack-checking.exp b/gdb/testsuite/gdb.base/stack-checking.exp
index 72b3ad1cc0cc..7e6789b7c04f 100644
--- a/gdb/testsuite/gdb.base/stack-checking.exp
+++ b/gdb/testsuite/gdb.base/stack-checking.exp
@@ -20,11 +20,11 @@  if { [prepare_for_testing "prepare" $testfile $srcfile \
 	  [list debug additional_flags=-fstack-check nowarnings]] != 0 } {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 
 # Test that the debugger is able to unwind to "main" at the next breakpoint
 # hit. The frame number of "main" should be passed into MAIN_FRAME_NUMBER."
diff --git a/gdb/testsuite/gdb.base/stack-protector.exp b/gdb/testsuite/gdb.base/stack-protector.exp
index 249baad8ac8e..b2d1e6000e8c 100644
--- a/gdb/testsuite/gdb.base/stack-protector.exp
+++ b/gdb/testsuite/gdb.base/stack-protector.exp
@@ -22,11 +22,11 @@ 
 # protection.
 if { !([test_compiler_info "gcc-*"] || [test_compiler_info "clang-*"])
      || [test_compiler_info {gcc-[0-3]-*}]
      || [test_compiler_info {gcc-4-0-*}]
      || [test_compiler_info {clang-[0-4]=*}] } {
-    return 0
+    return
 }
 
 standard_testfile
 
 set protector_options { "-fno-stack-protector" "-fstack-protector" \
diff --git a/gdb/testsuite/gdb.base/structs2.exp b/gdb/testsuite/gdb.base/structs2.exp
index 76deeae53839..ce8b0c00769f 100644
--- a/gdb/testsuite/gdb.base/structs2.exp
+++ b/gdb/testsuite/gdb.base/structs2.exp
@@ -18,11 +18,11 @@  standard_testfile .c
 if { [prepare_for_testing "failed to prepare" $testfile $srcfile {debug}] } {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 gdb_test "f" \
     ".*bkpt = 0.*" \
     "structs2 sanity check"
diff --git a/gdb/testsuite/gdb.base/sym-file.exp b/gdb/testsuite/gdb.base/sym-file.exp
index fe7b5ad13fa0..022c1eedbd9e 100644
--- a/gdb/testsuite/gdb.base/sym-file.exp
+++ b/gdb/testsuite/gdb.base/sym-file.exp
@@ -37,11 +37,11 @@  set target_size TARGET_UNKNOWN
 if {[is_lp64_target]} {
     set target_size TARGET_LP64
 } elseif {[is_ilp32_target]} {
    set target_size TARGET_ILP32
 } else {
-    return 0
+    return
 }
 
 set main_basename sym-file-main
 set loader_basename sym-file-loader
 set lib_basename sym-file-lib
diff --git a/gdb/testsuite/gdb.base/symlink-sourcefile.exp b/gdb/testsuite/gdb.base/symlink-sourcefile.exp
index bc2249071eb5..fc6a0c08b2d5 100644
--- a/gdb/testsuite/gdb.base/symlink-sourcefile.exp
+++ b/gdb/testsuite/gdb.base/symlink-sourcefile.exp
@@ -26,11 +26,11 @@  set srcfilelink [standard_output_file $linksrc]
 remote_file host delete $srcfilelink
 set status [remote_exec host \
 		"ln -sf $srcdir/$subdir/$srcfile $srcfilelink"]
 if {[lindex $status 0] != 0} {
     unsupported "$test (host does not support symbolic links)"
-    return 0
+    return
 }
 
 if {[prepare_for_testing $testfile $testfile $srcfilelink]} {
     return
 }
diff --git a/gdb/testsuite/gdb.base/term.exp b/gdb/testsuite/gdb.base/term.exp
index b615d9a410e9..8612a04e57b9 100644
--- a/gdb/testsuite/gdb.base/term.exp
+++ b/gdb/testsuite/gdb.base/term.exp
@@ -24,11 +24,11 @@  if { [prepare_for_testing "failed to prepare" term term.c] } {
 gdb_test "info terminal" \
     "No saved terminal information.*" \
     "test info terminal pre-execution"
 
 if {![runto break_here]} {
-    return 0
+    return
 }
 
 # Read the inferior's terminal settings, saved in the T global variable.
 
 proc read_term_settings_from_inferior {} {
diff --git a/gdb/testsuite/gdb.base/type-opaque.exp b/gdb/testsuite/gdb.base/type-opaque.exp
index 7c4d24eccb9b..f173639a02ac 100644
--- a/gdb/testsuite/gdb.base/type-opaque.exp
+++ b/gdb/testsuite/gdb.base/type-opaque.exp
@@ -36,11 +36,11 @@  if { [prepare_for_testing "prepare" $testfile $execsrc \
 }
 
 gdb_load_shlib ${libobj}
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 
 # DWARF3: An incomplete structure, union or class type is represented by
 # a structure, union or class entry that does not have a byte size attribute
diff --git a/gdb/testsuite/gdb.base/until-nodebug.exp b/gdb/testsuite/gdb.base/until-nodebug.exp
index 5980bc435ced..01be462bb86f 100644
--- a/gdb/testsuite/gdb.base/until-nodebug.exp
+++ b/gdb/testsuite/gdb.base/until-nodebug.exp
@@ -21,11 +21,11 @@  standard_testfile advance.c
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile nodebug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Without debug information, the program stops at the next
 # instruction, which is still in main.
 gdb_test "until" "in main .*" "until 1"
diff --git a/gdb/testsuite/gdb.base/until.exp b/gdb/testsuite/gdb.base/until.exp
index 58f9174af988..5aeb896e3118 100644
--- a/gdb/testsuite/gdb.base/until.exp
+++ b/gdb/testsuite/gdb.base/until.exp
@@ -24,11 +24,11 @@  set bp_location1 [gdb_get_line_number "set breakpoint 1 here"]
 set bp_location19 [gdb_get_line_number "set breakpoint 19 here"]
 set bp_location20 [gdb_get_line_number "set breakpoint 20 here"]
 set bp_location21 [gdb_get_line_number "set breakpoint 21 here"]
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Verify that "until <location>" works.  (This is really just syntactic
 # sugar for "tbreak <location>; continue".)
 #
diff --git a/gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl b/gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl
index 471342684aec..ed7bf83752fd 100644
--- a/gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl
+++ b/gdb/testsuite/gdb.base/unwind-on-each-insn.exp.tcl
@@ -28,11 +28,11 @@  if {[prepare_for_testing_full "failed to prepare" \
 	      $srcfile $srcfile_flags $srcfile2 $srcfile2_flags]]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # Return a two element list, the first element is the stack-pointer
 # value (from the $sp register), and the second element is the frame
 # base address (from the 'info frame' output).
diff --git a/gdb/testsuite/gdb.base/unwindonsignal.exp b/gdb/testsuite/gdb.base/unwindonsignal.exp
index cd98b9fdd02f..aed8ef6f4c75 100644
--- a/gdb/testsuite/gdb.base/unwindonsignal.exp
+++ b/gdb/testsuite/gdb.base/unwindonsignal.exp
@@ -25,11 +25,11 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if { ![runto_main] } {
-    return 0
+    return
 }
 
 gdb_test "break stop_here" "Breakpoint \[0-9\]* at .*"
 gdb_test "continue" "Continuing.*Breakpoint \[0-9\]*, stop_here.*" \
     "continue to breakpoint at stop_here"
@@ -66,11 +66,11 @@  if {[gdb_test "call gen_signal ()"  \
 	      "while in a function called from GDB\\.  GDB has restored the context" \
 	      "to what it was before the call\\.  To change this behavior use" \
 	      "\"set unwind-on-signal off\"\\.  Evaluation of the expression containing" \
 	      "the function \\(gen_signal\\) will be abandoned\\."] \
 	 "unwindonsignal, inferior function call signaled"] != 0} {
-    return 0
+    return
 }
 
 # Verify the stack got unwound.
 gdb_test "bt" \
     "#0 *\[x0-9a-f in\]*stop_here \\(.*\\) at .*#1 *\[x0-9a-f in\]*main \\(.*\\) at .*" \
diff --git a/gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp b/gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp
index 85494e5463ed..3f853b51527f 100644
--- a/gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp
+++ b/gdb/testsuite/gdb.base/watchpoint-reuse-slot.exp
@@ -37,11 +37,11 @@  standard_testfile
 if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return
 }
 
 if {![runto_main]} {
-    return 0
+    return
 }
 
 # The line we'll be stepping.
 set srcline [gdb_get_line_number "stepi line"]