From d8a760307e43031033b5607264f7edd8ecfe73a4 Mon Sep 17 00:00:00 2001 From: Jonathan Rose Date: Fri, 25 Oct 2013 21:28:32 +0000 Subject: ARI recordings: Issue HTTP failures for recording requests with file conflicts If a file already exists in the recordings directory with the same name as what we would record, issue a 422 instead of relying on the internal failure and issuing success. (closes issue ASTERISK-22623) Reported by: Joshua Colp Review: https://reviewboard.asterisk.org/r/2922/ ........ Merged revisions 401973 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@401999 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- res/res_ari_channels.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'res/res_ari_channels.c') diff --git a/res/res_ari_channels.c b/res/res_ari_channels.c index af7f17df2..8ff4c065c 100644 --- a/res/res_ari_channels.c +++ b/res/res_ari_channels.c @@ -992,7 +992,7 @@ static void ast_ari_record_channel_cb( case 501: /* Not Implemented */ case 400: /* Invalid parameters */ case 404: /* Channel not found */ - case 409: /* Channel is not in a Stasis application; the channel is currently bridged with other channels; A recording with the same name is currently in progress. */ + case 409: /* Channel is not in a Stasis application; the channel is currently bridged with other hcannels; A recording with the same name already exists on the system and can not be overwritten because it is in progress or ifExists=fail */ is_valid = 1; break; default: -- cgit v1.2.3