[OpenSIPS-Devel] tm hash deadlock patch

Eric Tamme eric.tamme at junctionnetworks.com
Thu Feb 28 18:33:57 CET 2013


We found that initial request callbacks are called with a lock on the tm
hash row so any callback that generates a new transaction, in our example
the pua module, can generate a hash for the new transaction with the same
key as the locked row thus creating a deadlock.

We modified the code to create a lock on the cell when t_newtran() calls
new_t and release the hash lock within new_t so that the callbacks are
called with a cell lock, not a row lock.  This looks l

Please review the attached patch.  The patch was made on a 1.6.4 code
base.  Let me know if you have any thoughts or concerns.

-Eric
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/devel/attachments/20130228/edf4e273/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: tm_hash_deadlock_patch
Type: application/octet-stream
Size: 3096 bytes
Desc: not available
URL: <http://lists.opensips.org/pipermail/devel/attachments/20130228/edf4e273/attachment.obj>


More information about the Devel mailing list