<p>Corey Farrell has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.asterisk.org/7028">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">stasis: Remove silly use of RAII_VAR in stasis_forward_all.<br><br>Change-Id: I46de4c968d40144d5b049966304ff66c1469fb65<br>---<br>M main/stasis.c<br>1 file changed, 4 insertions(+), 3 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/28/7028/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">diff --git a/main/stasis.c b/main/stasis.c<br>index a82e938..74d5df8 100644<br>--- a/main/stasis.c<br>+++ b/main/stasis.c<br>@@ -908,7 +908,7 @@<br> {<br>     int res;<br>      size_t idx;<br>-  RAII_VAR(struct stasis_forward *, forward, NULL, ao2_cleanup);<br>+       struct stasis_forward *forward;<br> <br>    if (!from_topic || !to_topic) {<br>               return NULL;<br>@@ -921,7 +921,7 @@<br> <br>  /* Forwards to ourselves are implicit. */<br>     if (to_topic == from_topic) {<br>-                return ao2_bump(forward);<br>+            return forward;<br>       }<br> <br>  forward->from_topic = ao2_bump(from_topic);<br>@@ -932,6 +932,7 @@<br>   if (res != 0) {<br>               ao2_unlock(from_topic);<br>               ao2_unlock(to_topic);<br>+                ao2_ref(forward, -1);<br>                 return NULL;<br>  }<br> <br>@@ -941,7 +942,7 @@<br>     ao2_unlock(from_topic);<br>       ao2_unlock(to_topic);<br> <br>-     return ao2_bump(forward);<br>+    return forward;<br> }<br> <br> static void subscription_change_dtor(void *obj)<br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/7028">change 7028</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/7028"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>
<div style="display:none"> Gerrit-Change-Id: I46de4c968d40144d5b049966304ff66c1469fb65 </div>
<div style="display:none"> Gerrit-Change-Number: 7028 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Corey Farrell <git@cfware.com> </div>