<p>Joshua Colp <strong>merged</strong> this change.</p><p><a href="https://gerrit.asterisk.org/7320">View Change</a></p><div style="white-space:pre-wrap">Approvals:
Richard Mudgett: Looks good to me, but someone else must approve
Joshua Colp: Looks good to me, approved
Jenkins2: Approved for Submit
</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">app: Remove silly usage of RAII_VAR.<br><br>Change-Id: Ideb594f7aae134974fb78d5477ba0853b97b8625<br>---<br>M main/app.c<br>1 file changed, 5 insertions(+), 8 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">diff --git a/main/app.c b/main/app.c<br>index 69c96c0..f35c4b7 100644<br>--- a/main/app.c<br>+++ b/main/app.c<br>@@ -3138,7 +3138,7 @@<br> <br> struct ast_mwi_state *ast_mwi_create(const char *mailbox, const char *context)<br> {<br>- RAII_VAR(struct ast_mwi_state *, mwi_state, NULL, ao2_cleanup);<br>+ struct ast_mwi_state *mwi_state;<br> <br> ast_assert(!ast_strlen_zero(mailbox));<br> <br>@@ -3148,6 +3148,7 @@<br> }<br> <br> if (ast_string_field_init(mwi_state, 256)) {<br>+ ao2_ref(mwi_state, -1);<br> return NULL;<br> }<br> if (!ast_strlen_zero(context)) {<br>@@ -3156,7 +3157,6 @@<br> ast_string_field_set(mwi_state, uniqueid, mailbox);<br> }<br> <br>- ao2_ref(mwi_state, +1);<br> return mwi_state;<br> }<br> <br>@@ -3329,8 +3329,8 @@<br> struct stasis_message_type *message_type,<br> struct ast_json *blob)<br> {<br>- RAII_VAR(struct ast_mwi_blob *, obj, NULL, ao2_cleanup);<br>- RAII_VAR(struct stasis_message *, msg, NULL, ao2_cleanup);<br>+ struct ast_mwi_blob *obj;<br>+ struct stasis_message *msg;<br> <br> ast_assert(blob != NULL);<br> <br>@@ -3349,11 +3349,8 @@<br> <br> /* This is not a normal MWI event. Only used by the MinivmNotify app. */<br> msg = stasis_message_create(message_type, obj);<br>- if (!msg) {<br>- return NULL;<br>- }<br>+ ao2_ref(obj, -1);<br> <br>- ao2_ref(msg, +1);<br> return msg;<br> }<br> <br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/7320">change 7320</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/7320"/><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: merged </div>
<div style="display:none"> Gerrit-Change-Id: Ideb594f7aae134974fb78d5477ba0853b97b8625 </div>
<div style="display:none"> Gerrit-Change-Number: 7320 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Corey Farrell <git@cfware.com> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins2 </div>
<div style="display:none"> Gerrit-Reviewer: Joshua Colp <jcolp@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Richard Mudgett <rmudgett@digium.com> </div>