mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-07-02 02:45:37 +08:00
Don't rely on inferior I/O in {call-signal-resume, unwindonsignal}.exp
These tests rely on inferior I/O, but that seems pointless and unrelated here. Simply remove the printf calls, and don't expect them. gdb/testsuite/ChangeLog: 2015-07-29 Pedro Alves <palves@redhat.com> * gdb.base/call-signal-resume.exp: Remove check for gdb,noinferiorio. Don't expect "no signal". Use gdb_test. * gdb.base/unwindonsignal.exp: Likewise. * gdb.base/call-signals.c (gen_signal): Remove printf call. * gdb.base/unwindonsignal.c (gen_signal): Likewise.
This commit is contained in:
@ -1,3 +1,11 @@
|
|||||||
|
2015-07-29 Pedro Alves <palves@redhat.com>
|
||||||
|
|
||||||
|
* gdb.base/call-signal-resume.exp: Remove check for
|
||||||
|
gdb,noinferiorio. Don't expect "no signal". Use gdb_test.
|
||||||
|
* gdb.base/unwindonsignal.exp: Likewise.
|
||||||
|
* gdb.base/call-signals.c (gen_signal): Remove printf call.
|
||||||
|
* gdb.base/unwindonsignal.c (gen_signal): Likewise.
|
||||||
|
|
||||||
2015-07-29 Pedro Alves <palves@redhat.com>
|
2015-07-29 Pedro Alves <palves@redhat.com>
|
||||||
|
|
||||||
* gdb.base/siginfo-addr.c (pass): New function.
|
* gdb.base/siginfo-addr.c (pass): New function.
|
||||||
|
@ -20,11 +20,6 @@
|
|||||||
# 2) Inferior is stopped at a signal. Upon resumption it should continue
|
# 2) Inferior is stopped at a signal. Upon resumption it should continue
|
||||||
# with that signal, regardless of whatever the hand-called function did.
|
# with that signal, regardless of whatever the hand-called function did.
|
||||||
|
|
||||||
if [target_info exists gdb,noinferiorio] {
|
|
||||||
verbose "Skipping call-signal-resume.exp because of no fileio capabilities."
|
|
||||||
continue
|
|
||||||
}
|
|
||||||
|
|
||||||
if [target_info exists gdb,nosignals] {
|
if [target_info exists gdb,nosignals] {
|
||||||
verbose "Skipping call-signal-resume.exp because of nosignals."
|
verbose "Skipping call-signal-resume.exp because of nosignals."
|
||||||
continue
|
continue
|
||||||
@ -72,15 +67,10 @@ gdb_test "continue" "Continuing.*Breakpoint \[0-9\]*, stop_one.*" \
|
|||||||
|
|
||||||
# Call function (causing the program to get a signal), and see if gdb handles
|
# Call function (causing the program to get a signal), and see if gdb handles
|
||||||
# it properly.
|
# it properly.
|
||||||
gdb_test_multiple "call gen_signal ()" \
|
if {[gdb_test "call gen_signal ()" \
|
||||||
"inferior function call signaled" {
|
"\[\r\n\]*The program being debugged was signaled.*" \
|
||||||
-re "\[\r\n\]*no signal\[\r\n\]+$gdb_prompt $" {
|
"inferior function call signaled"] != 0} {
|
||||||
unsupported "inferior function call signaled"
|
|
||||||
return 0
|
return 0
|
||||||
}
|
|
||||||
-re "\[\r\n\]*The program being debugged was signaled.*\[\r\n\]+$gdb_prompt $" {
|
|
||||||
pass "inferior function call signaled"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
set frame_number [get_dummy_frame_number]
|
set frame_number [get_dummy_frame_number]
|
||||||
|
@ -18,7 +18,6 @@
|
|||||||
/* Support program for testing handling of inferior function calls
|
/* Support program for testing handling of inferior function calls
|
||||||
in the presence of signals. */
|
in the presence of signals. */
|
||||||
|
|
||||||
#include <stdio.h>
|
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
@ -32,8 +31,6 @@ gen_signal ()
|
|||||||
{
|
{
|
||||||
/* According to sigall.exp, SIGABRT is always supported. */
|
/* According to sigall.exp, SIGABRT is always supported. */
|
||||||
kill (getpid (), SIGABRT);
|
kill (getpid (), SIGABRT);
|
||||||
/* If we get here we couldn't generate a signal, tell dejagnu. */
|
|
||||||
printf ("no signal\n");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Easy place to set a breakpoint. */
|
/* Easy place to set a breakpoint. */
|
||||||
|
@ -17,7 +17,6 @@
|
|||||||
|
|
||||||
/* Support program for testing unwindonsignal. */
|
/* Support program for testing unwindonsignal. */
|
||||||
|
|
||||||
#include <stdio.h>
|
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
@ -26,8 +25,6 @@ gen_signal ()
|
|||||||
{
|
{
|
||||||
/* According to sigall.exp, SIGABRT is always supported. */
|
/* According to sigall.exp, SIGABRT is always supported. */
|
||||||
kill (getpid (), SIGABRT);
|
kill (getpid (), SIGABRT);
|
||||||
/* If we get here we couldn't generate a signal, tell dejagnu. */
|
|
||||||
printf ("no signal\n");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Easy place to set a breakpoint. */
|
/* Easy place to set a breakpoint. */
|
||||||
|
@ -13,11 +13,6 @@
|
|||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
if [target_info exists gdb,noinferiorio] {
|
|
||||||
verbose "Skipping unwindonsignal.exp because of no fileio capabilities."
|
|
||||||
continue
|
|
||||||
}
|
|
||||||
|
|
||||||
if [target_info exists gdb,nosignals] {
|
if [target_info exists gdb,nosignals] {
|
||||||
verbose "Skipping unwindonsignal.exp because of nosignals."
|
verbose "Skipping unwindonsignal.exp because of nosignals."
|
||||||
continue
|
continue
|
||||||
@ -58,15 +53,10 @@ gdb_test "show unwindonsignal" \
|
|||||||
|
|
||||||
# Call function (causing the program to get a signal), and see if gdb handles
|
# Call function (causing the program to get a signal), and see if gdb handles
|
||||||
# it properly.
|
# it properly.
|
||||||
gdb_test_multiple "call gen_signal ()" \
|
if {[gdb_test "call gen_signal ()" \
|
||||||
"unwindonsignal, inferior function call signaled" {
|
"\[\r\n\]*The program being debugged was signaled.*" \
|
||||||
-re "\[\r\n\]*no signal\[\r\n\]+$gdb_prompt $" {
|
"unwindonsignal, inferior function call signaled"] != 0} {
|
||||||
unsupported "unwindonsignal, inferior function call signaled"
|
|
||||||
return 0
|
return 0
|
||||||
}
|
|
||||||
-re "\[\r\n\]*The program being debugged was signaled.*\[\r\n\]+$gdb_prompt $" {
|
|
||||||
pass "unwindonsignal, inferior function call signaled"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# Verify the stack got unwound.
|
# Verify the stack got unwound.
|
||||||
|
Reference in New Issue
Block a user