[asterisk-dev] [Code Review] Make user removals and traversals thread safe in meetme

Jeff Peeler jpeeler at digium.com
Wed Jun 30 09:47:31 CDT 2010

This is an automatically generated e-mail. To reply, visit:

(Updated 2010-06-30 09:47:31.279013)

Review request for Asterisk Developers.


Fixed change of behavior for CLI completion. Commented delayed reference handing after ao2_find usage in find_user. I do not understand the advantage of the suggested use of ao2_callbacks since wrapper functions would need to be created.


The race conditions present in meetme involves the user list where a lack of locking has the potential for a user to be removed during a traversal or as in the case of the reporter after checking if the list is empty. Adding locking would mostly solve the problem, but there were some cases that abuse of the list lock was required to protect operations on the user (such as after using AST_LIST_LAST). Therefore I went the slightly more invasive route of ao2-ifying the users to make everything completely safe.

This addresses bug 17390.

Diffs (updated)

  /branches/1.4/apps/app_meetme.c 273189 

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


Tested joining, parting conference and verified assigned user number was as expected. Randomly tested ejecting and kicking all.



More information about the asterisk-dev mailing list