<p>Corey Farrell has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.asterisk.org/7249">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">aoc: Fix memory management issues.<br><br>aoc_publish_blob failed to check for msg allocation error and never<br>released msg.<br><br>Change-Id: Ib31a9ffb81056a0d496a49d7eec795005a44bcd5<br>---<br>M main/aoc.c<br>1 file changed, 4 insertions(+), 1 deletion(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/49/7249/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">diff --git a/main/aoc.c b/main/aoc.c<br>index 451b219..3487948 100644<br>--- a/main/aoc.c<br>+++ b/main/aoc.c<br>@@ -1860,7 +1860,10 @@<br> msg = stasis_message_create(msg_type, aoc_event);<br> ao2_ref(aoc_event, -1);<br> <br>- stasis_publish(ast_manager_get_topic(), msg);<br>+ if (msg) {<br>+ stasis_publish(ast_manager_get_topic(), msg);<br>+ ao2_ref(msg, -1);<br>+ }<br> }<br> <br> static struct ast_manager_event_blob *aoc_to_ami(struct stasis_message *message,<br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/7249">change 7249</a>. To unsubscribe, visit <a href="https://gerrit.asterisk.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.asterisk.org/7249"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 15 </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>
<div style="display:none"> Gerrit-Change-Id: Ib31a9ffb81056a0d496a49d7eec795005a44bcd5 </div>
<div style="display:none"> Gerrit-Change-Number: 7249 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Corey Farrell <git@cfware.com> </div>