diff options
author | Pedro Alves <palves@redhat.com> | 2016-05-25 18:35:09 +0100 |
---|---|---|
committer | Pedro Alves <palves@redhat.com> | 2016-05-25 18:35:09 +0100 |
commit | a0de87e7be6a58dfeb9bfb00172dbd975dabb72e (patch) | |
tree | 4430d6254631a314432927aa2215ead45cacd9e4 | |
parent | 92e1921256be5093311c6b616e12060c6e1dcf28 (diff) | |
download | binutils-a0de87e7be6a58dfeb9bfb00172dbd975dabb72e.zip binutils-a0de87e7be6a58dfeb9bfb00172dbd975dabb72e.tar.gz binutils-a0de87e7be6a58dfeb9bfb00172dbd975dabb72e.tar.bz2 |
Make gdb/linux-nat.c consider a waitstatus pending on the infrun side
Working on the fix for gdb/19828, I saw
gdb.threads/attach-many-short-lived-threads.exp fail once in an
unusual way. Unfortunately I didn't keep debug logs, but it's an
issue similar to what's been fixed in remote.c a while ago --
linux-nat.c was not fetching the pending status from the right place.
gdb/ChangeLog:
2016-05-25 Pedro Alves <palves@redhat.com>
PR gdb/19828
* linux-nat.c (get_pending_status): If the thread reported the
event to the core and it's pending, use the pending status signal
number.
-rw-r--r-- | gdb/ChangeLog | 7 | ||||
-rw-r--r-- | gdb/linux-nat.c | 5 |
2 files changed, 11 insertions, 1 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 3ee9cb4..179acf0 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,10 @@ +2016-05-25 Pedro Alves <palves@redhat.com> + + PR gdb/19828 + * linux-nat.c (get_pending_status): If the thread reported the + event to the core and it's pending, use the pending status signal + number. + 2016-05-17 Simon Marchi <simon.marchi@ericsson.com> PR gdb/20045 diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c index 0829bcb..ea171b0 100644 --- a/gdb/linux-nat.c +++ b/gdb/linux-nat.c @@ -1236,7 +1236,10 @@ get_pending_status (struct lwp_info *lp, int *status) { struct thread_info *tp = find_thread_ptid (lp->ptid); - signo = tp->suspend.stop_signal; + if (tp->suspend.waitstatus_pending_p) + signo = tp->suspend.waitstatus.value.sig; + else + signo = tp->suspend.stop_signal; } else if (!target_is_non_stop_p ()) { |