]> git.ipfire.org Git - thirdparty/asterisk.git/commit
taskprocessor: Prevent race creating new taskprocessor.
authorCorey Farrell <git@cfware.com>
Mon, 12 Nov 2018 18:23:34 +0000 (13:23 -0500)
committerCorey Farrell <git@cfware.com>
Fri, 16 Nov 2018 13:55:56 +0000 (08:55 -0500)
commit2f75f1941a4dd6300589947652211708a22bc3ed
tree886bebc4a15a56c755b6717ee60d3b2539caf578
parent4ae848e27a4ac0425b3a88cc9d109a424964b2d4
taskprocessor: Prevent race creating new taskprocessor.

Task processors are retrieved using a 'get or create' pattern.  The
singleton container was unlocked between the get and create steps so
it's possible that two threads could create task processors with the
same name at the same time.

Change-Id: Id64fae94a6a1e940ddf38fde622dcd4391635382
main/taskprocessor.c