Skip to content
Snippets Groups Projects
Commit 91fc57f5 authored by Sungtae Kim's avatar Sungtae Kim Committed by George Joseph
Browse files

res_ari: Fix wrong media uri handle for channel play

Fixed wrong null object handle in
/channels/<channel_id>/play request handler.

ASTERISK-29188

Change-Id: I6691c640247a51ad15f23e4a203ca8430809bafe
parent 7d4ae7dc
No related branches found
No related tags found
3 merge requests!138Merge branch asterisk-20.3.0 into devel properly,!123Merge asterisk '20.3.0' into devel,!118Draft: manager: AOC-S support for AOCMessage
......@@ -489,6 +489,13 @@ struct stasis_app_playback *stasis_app_control_play_uri(
for (i = 0; i < media_count; i++) {
char *media_uri;
if (ast_strlen_zero(media[i])) {
ast_log(LOG_ERROR, "Attempted to play media on channel '%s' but no media URI was provided.\n",
stasis_app_control_get_channel_id(control));
ao2_ref(playback, -1);
return NULL;
}
media_uri = ast_malloc(strlen(media[i]) + 1);
if (!media_uri) {
ao2_ref(playback, -1);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment