<p>George Joseph <strong>submitted</strong> this change.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/15252">View Change</a></p><div style="white-space:pre-wrap">Approvals:
George Joseph: Looks good to me, approved; Approved for Submit
</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">res_ari: Fix wrong media uri handle for channel play<br><br>Fixed wrong null object handle in<br>/channels/<channel_id>/play request handler.<br><br>ASTERISK-29188<br><br>Change-Id: I6691c640247a51ad15f23e4a203ca8430809bafe<br>---<br>M res/res_stasis_playback.c<br>1 file changed, 7 insertions(+), 0 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/res/res_stasis_playback.c b/res/res_stasis_playback.c</span><br><span>index 7665d5f..d60a49a 100644</span><br><span>--- a/res/res_stasis_playback.c</span><br><span>+++ b/res/res_stasis_playback.c</span><br><span>@@ -489,6 +489,13 @@</span><br><span> for (i = 0; i < media_count; i++) {</span><br><span> char *media_uri;</span><br><span> </span><br><span style="color: hsl(120, 100%, 40%);">+ if (ast_strlen_zero(media[i])) {</span><br><span style="color: hsl(120, 100%, 40%);">+ ast_log(LOG_ERROR, "Attempted to play media on channel '%s' but no media URI was provided.\n",</span><br><span style="color: hsl(120, 100%, 40%);">+ stasis_app_control_get_channel_id(control));</span><br><span style="color: hsl(120, 100%, 40%);">+ ao2_ref(playback, -1);</span><br><span style="color: hsl(120, 100%, 40%);">+ return NULL;</span><br><span style="color: hsl(120, 100%, 40%);">+ }</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span> media_uri = ast_malloc(strlen(media[i]) + 1);</span><br><span> if (!media_uri) {</span><br><span> ao2_ref(playback, -1);</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/15252">change 15252</a>. To unsubscribe, or for help writing mail filters, 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/c/asterisk/+/15252"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 18 </div>
<div style="display:none"> Gerrit-Change-Id: I6691c640247a51ad15f23e4a203ca8430809bafe </div>
<div style="display:none"> Gerrit-Change-Number: 15252 </div>
<div style="display:none"> Gerrit-PatchSet: 2 </div>
<div style="display:none"> Gerrit-Owner: sungtae kim <pchero21@gmail.com> </div>
<div style="display:none"> Gerrit-Reviewer: Friendly Automation </div>
<div style="display:none"> Gerrit-Reviewer: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-MessageType: merged </div>