From: Thiago Jung Bauermann Date: Wed, 29 Apr 2026 23:03:55 +0000 (-0300) Subject: GDB: testsuite: x86, amd64, i386: Don't return value from top-level (manual) X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f6c5da4723b85481b5f65e8783eecfae63a89e93;p=thirdparty%2Fbinutils-gdb.git GDB: testsuite: x86, amd64, i386: Don't return value from top-level (manual) This patch manually changes the "return -1" statements that weren't caught by the sed command. In amd64-shadow-stack-cmds.exp the return statements have extra indentation due to being inside a save_vars block. In i386-bp_permanent.exp this was caused by misaligned lines, which are now fixed. Approved-By: Tom Tromey --- diff --git a/gdb/testsuite/gdb.arch/amd64-shadow-stack-cmds.exp b/gdb/testsuite/gdb.arch/amd64-shadow-stack-cmds.exp index e4daecb590d..e67a0c2e4a1 100644 --- a/gdb/testsuite/gdb.arch/amd64-shadow-stack-cmds.exp +++ b/gdb/testsuite/gdb.arch/amd64-shadow-stack-cmds.exp @@ -44,12 +44,12 @@ save_vars { ::env(GLIBC_TUNABLES) } { if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \ {debug additional_flags="-fcf-protection=return"}] } { - return -1 + return } clean_restart ${::testfile} if { ![runto_main] } { - return -1 + return } with_test_prefix "test inferior call and continue" { @@ -85,7 +85,7 @@ save_vars { ::env(GLIBC_TUNABLES) } { clean_restart ${::testfile} if { ![runto_main] } { - return -1 + return } set call1_line [ gdb_get_line_number "break call1" ] @@ -122,7 +122,7 @@ save_vars { ::env(GLIBC_TUNABLES) } { clean_restart ${::testfile} if { ![runto_main] } { - return -1 + return } with_test_prefix "test return from past frame" { diff --git a/gdb/testsuite/gdb.arch/i386-bp_permanent.exp b/gdb/testsuite/gdb.arch/i386-bp_permanent.exp index ef4d0370de8..9805f562634 100644 --- a/gdb/testsuite/gdb.arch/i386-bp_permanent.exp +++ b/gdb/testsuite/gdb.arch/i386-bp_permanent.exp @@ -40,7 +40,7 @@ clean_restart $::testfile # if {![runto_main]} { - return -1 + return } set function "standard" @@ -53,8 +53,8 @@ set retcode [gdb_test_multiple "disassemble $function" "disassemble function '$f }] if {$retcode != 0} { - fail "disassemble failed, skipping entire test." - return -1 + fail "disassemble failed, skipping entire test." + return } gdb_breakpoint "*$address_bp"