diff options
author | Kozlov Dmitry <xeb@mail.ru> | 2012-06-21 16:38:44 +0400 |
---|---|---|
committer | Kozlov Dmitry <xeb@mail.ru> | 2012-06-21 16:38:44 +0400 |
commit | 9fa73e091942f7420de44fa1433725a3abe960e9 (patch) | |
tree | 8dc479093cb1c70541aff8520210d925ebaa21b2 | |
parent | 8f83530b83bf8b8556a797ecfe9799bbd1eb5750 (diff) | |
download | accel-ppp-9fa73e091942f7420de44fa1433725a3abe960e9.tar.gz accel-ppp-9fa73e091942f7420de44fa1433725a3abe960e9.zip |
fixed race on termination
-rw-r--r-- | accel-pppd/triton/triton.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/accel-pppd/triton/triton.c b/accel-pppd/triton/triton.c index 02af0354..897a4ea4 100644 --- a/accel-pppd/triton/triton.c +++ b/accel-pppd/triton/triton.c @@ -374,8 +374,10 @@ void __export triton_context_unregister(struct triton_context_t *ud) spin_unlock(&ctx_list_lock); if (terminate) { + spin_lock(&threads_lock); list_for_each_entry(t, &threads, entry) triton_thread_wakeup(t); + spin_unlock(&threads_lock); } } |