[asterisk-dev] [Code Review] Fix deadlock in chan_sip.

Matthew Nicholson mnicholson at digium.com
Wed Jun 17 17:56:07 CDT 2009


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://reviewboard.digium.com/r/285/
-----------------------------------------------------------

(Updated 2009-06-17 17:56:07.834749)


Review request for Asterisk Developers.


Changes
-------

Copy the result of pbx_builtin_getvar_helper() using ast_strdupa() in order to hold the channel lock for less time.


Summary
-------

This patch resolves a deadlock in chan_sip caused by the channel pvt getting locked before the channel lock.  This change also fixes a race condition involving a channel variable returned by pbx_builtin_get_var_helper().


Diffs (updated)
-----

  /trunk/channels/chan_sip.c 201533 

Diff: http://reviewboard.digium.com/r/285/diff


Testing
-------

Lightly tested in my lab environment.


Thanks,

Matthew




More information about the asterisk-dev mailing list