aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Snyder <msnyder@vmware.com>2001-05-30 18:15:45 +0000
committerMichael Snyder <msnyder@vmware.com>2001-05-30 18:15:45 +0000
commit5f885618b6ab3b98f888aea51eb3cef7b742c718 (patch)
tree303e34e53bd1b3295ac07f02eb0edff57431a811
parent4dc8668677b161cbbbf864f46c68abd65e153131 (diff)
downloadgdb-5f885618b6ab3b98f888aea51eb3cef7b742c718.zip
gdb-5f885618b6ab3b98f888aea51eb3cef7b742c718.tar.gz
gdb-5f885618b6ab3b98f888aea51eb3cef7b742c718.tar.bz2
2001-05-25 Michael Snyder <msnyder@redhat.com>
* lin-lwp.c (stop_wait_callback): Discard redundant SIGINT events.
-rw-r--r--gdb/ChangeLog1
-rw-r--r--gdb/lin-lwp.c11
2 files changed, 11 insertions, 1 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 4b1253b..fb34c10 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -28,6 +28,7 @@
2001-05-25 Michael Snyder <msnyder@redhat.com>
+ * lin-lwp.c (stop_wait_callback): Discard redundant SIGINT events.
* remote.c (remote_write_bytes): Update 'p' packet pointer.
2001-05-25 Jim Blandy <jimb@redhat.com>
diff --git a/gdb/lin-lwp.c b/gdb/lin-lwp.c
index 2d2a2b6..923d43b 100644
--- a/gdb/lin-lwp.c
+++ b/gdb/lin-lwp.c
@@ -610,6 +610,15 @@ stop_wait_callback (struct lwp_info *lp, void *data)
- DECR_PC_AFTER_BREAK,
pid_to_ptid (pid));
}
+ else if (WSTOPSIG (status) == SIGINT &&
+ signal_pass_state (SIGINT) == 0)
+ {
+ /* Since SIGINT gets forwarded to the entire process group
+ (in the case where ^C/BREAK is typed at the tty/console),
+ just ignore all SIGINT events from all lwp's except for
+ the one that was caught by lin_lwp_wait. */
+ ; /* Don't save. Signal will disappear into oblivion. */
+ }
else
{
if (debug_lin_lwp)
@@ -618,7 +627,7 @@ stop_wait_callback (struct lwp_info *lp, void *data)
strsignal (WSTOPSIG (status)), pid);
/* The thread was stopped with a signal other than
- SIGSTOP, and didn't accidentiliy trip a breakpoint.
+ SIGSTOP, and didn't accidentally trip a breakpoint.
Record the wait status. */
lp->status = status;
}