summaryrefslogtreecommitdiffstats
path: root/lib/libthr/thread/thr_init.c
diff options
context:
space:
mode:
authormtm <mtm@FreeBSD.org>2004-03-28 14:05:28 +0000
committermtm <mtm@FreeBSD.org>2004-03-28 14:05:28 +0000
commitc715901410e98c7b0c336278828765e4285964d3 (patch)
treec847bc30278d22c01ea70ac7fbb7c69dc9831151 /lib/libthr/thread/thr_init.c
parent1425c998a18db105fcdc560157ebc5bb857ab2e6 (diff)
downloadFreeBSD-src-c715901410e98c7b0c336278828765e4285964d3.zip
FreeBSD-src-c715901410e98c7b0c336278828765e4285964d3.tar.gz
Remove the garbage collector thread. All resources are freed
in-line. If the exiting thread cannot release a resource, then the next thread to exit will release it.
Diffstat (limited to 'lib/libthr/thread/thr_init.c')
-rw-r--r--lib/libthr/thread/thr_init.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/libthr/thread/thr_init.c b/lib/libthr/thread/thr_init.c
index 68532f1..d74ed2d 100644
--- a/lib/libthr/thread/thr_init.c
+++ b/lib/libthr/thread/thr_init.c
@@ -224,7 +224,6 @@ init_tdlist(struct pthread *td, int reinit)
}
}
_pthread_mutex_destroy(&dead_list_lock);
- _pthread_cond_destroy(&_gc_cond);
} else {
TAILQ_INIT(&_thread_list);
TAILQ_INIT(&_dead_list);
@@ -235,11 +234,10 @@ init_tdlist(struct pthread *td, int reinit)
/*
* Initialize the active thread list lock and the
- * dead threads list lock & associated condition variable.
+ * dead threads list lock.
*/
memset(&thread_list_lock, 0, sizeof(spinlock_t));
- if (_pthread_mutex_init(&dead_list_lock,NULL) != 0 ||
- _pthread_cond_init(&_gc_cond,NULL) != 0)
+ if (_pthread_mutex_init(&dead_list_lock,NULL) != 0)
PANIC("Failed to initialize garbage collector primitives");
}
OpenPOWER on IntegriCloud