aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Kratochvil <jan.kratochvil@redhat.com>2010-05-28 18:00:46 +0000
committerJan Kratochvil <jan.kratochvil@redhat.com>2010-05-28 18:00:46 +0000
commit1e225492405c82b0b7b9973d8f549e1411168e3d (patch)
tree1ee5cbe8fdf093a0104f49202a38edbdce5b7498
parent3def43e060c89f10b775951cfec9ba963e5db481 (diff)
downloadgdb-1e225492405c82b0b7b9973d8f549e1411168e3d.zip
gdb-1e225492405c82b0b7b9973d8f549e1411168e3d.tar.gz
gdb-1e225492405c82b0b7b9973d8f549e1411168e3d.tar.bz2
gdb/
* linux-nat.c (linux_nat_wait_1): Do not call linux_nat_core_of_thread_1 on TARGET_WAITKIND_EXITED or TARGET_WAITKIND_SIGNALLED.
-rw-r--r--gdb/ChangeLog6
-rw-r--r--gdb/linux-nat.c8
2 files changed, 13 insertions, 1 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index b7ca515..cf1b585 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,9 @@
+2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
+
+ * linux-nat.c (linux_nat_wait_1): Do not call
+ linux_nat_core_of_thread_1 on TARGET_WAITKIND_EXITED or
+ TARGET_WAITKIND_SIGNALLED.
+
2010-05-27 Joel Brobecker <brobecker@adacore.com>
* ada-lang.c (ada_inferior_data): New struct.
diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
index 8180248..b0f79f1 100644
--- a/gdb/linux-nat.c
+++ b/gdb/linux-nat.c
@@ -3626,7 +3626,13 @@ retry:
fprintf_unfiltered (gdb_stdlog, "LLW: exit\n");
restore_child_signals_mask (&prev_mask);
- lp->core = linux_nat_core_of_thread_1 (lp->ptid);
+
+ if (ourstatus->kind == TARGET_WAITKIND_EXITED
+ || ourstatus->kind == TARGET_WAITKIND_SIGNALLED)
+ lp->core = -1;
+ else
+ lp->core = linux_nat_core_of_thread_1 (lp->ptid);
+
return lp->ptid;
}