aboutsummaryrefslogtreecommitdiff
path: root/gdb/thread.c
diff options
context:
space:
mode:
authorJason Molenda <jmolenda@apple.com>1999-08-23 22:40:00 +0000
committerJason Molenda <jmolenda@apple.com>1999-08-23 22:40:00 +0000
commit53a5351d907ef4eacd463a48a86d35b2b70b9f60 (patch)
tree22c35199ec70962e33c63d2111f333bfdcce02e1 /gdb/thread.c
parent093505ad6138b9e165876765ecd667c90fc921ae (diff)
downloadgdb-53a5351d907ef4eacd463a48a86d35b2b70b9f60.zip
gdb-53a5351d907ef4eacd463a48a86d35b2b70b9f60.tar.gz
gdb-53a5351d907ef4eacd463a48a86d35b2b70b9f60.tar.bz2
import gdb-1999-08-23 snapshot
Diffstat (limited to 'gdb/thread.c')
-rw-r--r--gdb/thread.c16
1 files changed, 6 insertions, 10 deletions
diff --git a/gdb/thread.c b/gdb/thread.c
index 4be1a74..4a2070b 100644
--- a/gdb/thread.c
+++ b/gdb/thread.c
@@ -160,6 +160,11 @@ delete_thread (pid)
else
thread_list = tp->next;
+ /* NOTE: this will take care of any left-over step_resume breakpoints,
+ but not any user-specified thread-specific breakpoints. */
+ if (tp->step_resume_breakpoint)
+ delete_breakpoint (tp->step_resume_breakpoint);
+
free (tp);
return;
@@ -350,20 +355,11 @@ prune_threads ()
{
struct thread_info *tp, *tpprev, *next;
- tpprev = 0;
for (tp = thread_list; tp; tp = next)
{
next = tp->next;
if (!thread_alive (tp))
- {
- if (tpprev)
- tpprev->next = next;
- else
- thread_list = next;
- free (tp);
- }
- else
- tpprev = tp;
+ delete_thread (tp->pid);
}
}