<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Apr 29, 2014 at 6:03 PM, Richard Kenner <span dir="ltr"><<a href="mailto:kenner@gnat.com" target="_blank">kenner@gnat.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class="">> If the channel still hangs around after the conference is destroyed<br>
> then there is a problem.<br>
<br>
</div>Am I missing something obvious: I'm looking in the confbridge_exec<br>
function.  I see a "conference = NULL" line, but no attempt to free<br>
that structure, which is what I understand will destroy the playback<br>
channel.  So where it is freed?<br clear="all"></blockquote><div><br></div><div>Conferences are reference counted objects. When the reference count reaches 0 on the conference object, its destructor is automatically called. The destructor, in this case, is destroy_conference_bridge. That is where the CBAnn channel should be hung up.<br>
<br>        /* Try to allocate memory for a new conference bridge, if we fail... this won't end well. */<br>        if (!(conference = ao2_alloc(sizeof(*conference), destroy_conference_bridge))) {<br>            ao2_unlock(conference_bridges);<br>
            ast_log(LOG_ERROR, "Conference '%s' could not be created.\n", conference_name);<br>            return NULL;<br>        }<br></div></div><br></div><div class="gmail_extra">If the reference count on the bridge is off, you should see the conference bridge 'hanging around' after the last participant has left. If so, please file a bug report. We'll need a REF_DEBUG log to figure out who the guilty party is in holding onto a reference. The easiest way to get that is to reproduce the problem using the latest from the 12 branch (as we made reference count debugging easier just recently). Enable REF_DEBUG in menuselect under Compiler Flags, make/make install, and re-run the scenario that reproduces the result. A refs file will be created in your Asterisk log directory - attach that to the issue along with DEBUG log.<br>
<br>Thanks!<br></div><div class="gmail_extra"><br>-- <br><div dir="ltr"><div>Matthew Jordan<br></div><div>Digium, Inc. | Engineering Manager</div><div>445 Jan Davis Drive NW - Huntsville, AL 35806 - USA</div><div>Check us out at: <a href="http://digium.com" target="_blank">http://digium.com</a> & <a href="http://asterisk.org" target="_blank">http://asterisk.org</a></div>
</div>
</div></div>