FreeBSD Bugzilla – Attachment 169926 Details for
Bug 209233
[patch] pthread_suspend_all_np races with check_suspend
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch to fix race
thr_suspend_np.diff (text/plain), 769 bytes, created by
Lawrence Esswood
on 2016-05-03 13:14:09 UTC
(
hide
)
Description:
Patch to fix race
Filename:
MIME Type:
Creator:
Lawrence Esswood
Created:
2016-05-03 13:14:09 UTC
Size:
769 bytes
patch
obsolete
>--- old/lib/libthr/thread/thr_suspend_np.c 2016-05-03 10:28:49.724147269 +0000 >+++ patched/lib/libthr/thread/thr_suspend_np.c 2016-05-03 10:27:23.133153259 +0000 >@@ -116,8 +116,7 @@ > TAILQ_FOREACH(thread, &_thread_list, tle) { > if (thread != curthread) { > THR_THREAD_LOCK(curthread, thread); >- if (thread->state != PS_DEAD && >- !(thread->flags & THR_FLAGS_SUSPENDED)) >+ if (thread->state != PS_DEAD) > thread->flags |= THR_FLAGS_NEED_SUSPEND; > THR_THREAD_UNLOCK(curthread, thread); > } >@@ -162,6 +161,9 @@ > { > uint32_t tmp; > >+ if(thread->state != PS_DEAD) >+ thread->flags |= THR_FLAGS_NEED_SUSPEND; >+ > while (thread->state != PS_DEAD && > !(thread->flags & THR_FLAGS_SUSPENDED)) { > thread->flags |= THR_FLAGS_NEED_SUSPEND;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 209233
: 169926 |
169969
|
169971
|
169973