[asterisk-dev] [Code Review] Fix crash during CDR update.

rmudgett reviewboard at asterisk.org
Fri Dec 16 11:25:28 CST 2011


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/1628/
-----------------------------------------------------------

Review request for Asterisk Developers.


Summary
-------

This patch simply adds lock protection around CDR API calls that access an ast_channel pointer.

The ast_cdr_setcid() and ast_cdr_update() were shown in ASTERISK-18836 to be called by different threads for the same channel.  The channel driver thread and the PBX thread running dialplan.


This addresses bug ASTERISK-18836.
    https://issues.asterisk.org/jira/browse/ASTERISK-18836


Diffs
-----

  http://svn.asterisk.org/svn/asterisk/branches/1.8/channels/sig_pri.c 341666 

Diff: https://reviewboard.asterisk.org/r/1628/diff


Testing
-------

It compiles and I can see the potential for reentrancy from other threads.


Thanks,

rmudgett

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20111216/4f2c9b49/attachment.htm>


More information about the asterisk-dev mailing list