summaryrefslogtreecommitdiff
path: root/lib/json.c
diff options
context:
space:
mode:
authorQuentin Young <qlyoung@cumulusnetworks.com>2017-06-07 20:34:09 +0000
committerQuentin Young <qlyoung@cumulusnetworks.com>2017-06-16 19:56:58 +0000
commit63ccb9cb12b559be539bc406f1b9ffc5cb3ac16a (patch)
treed03f194f1437b5a656bb48ddb029e6f4c7322a8a /lib/json.c
parent62e4232010330e515630399838288f6281d04de6 (diff)
lib: add mt-safe thread_cancel
This patch implements an MT-safe version of thread_cancel() in thread_cancel_async(). Behavior as follows: * Cancellation requests are queued into a list * Cancellation requests made from the same pthread as the thread_master owner are serviced immediately (thread_cancel()) * Cancellation requests made from a separate pthread are queued and the call blocks on a condition variable until the owning pthread services the request, at which point the condition variable is signaled and execution continues (thread_cancel_async()) Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
Diffstat (limited to 'lib/json.c')
0 files changed, 0 insertions, 0 deletions