]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
FS-5799 extra channel variables when leaving a message
authorBrian West <brian@freeswitch.org>
Mon, 24 Feb 2014 09:57:27 +0000 (03:57 -0600)
committerBrian West <brian@freeswitch.org>
Mon, 24 Feb 2014 09:57:27 +0000 (03:57 -0600)
src/mod/applications/mod_voicemail/mod_voicemail.c

index edf4381472ec74f776cd18fde08a7ca09c9315dc..278be2596912811739be38b5f543738593947cbf 100644 (file)
@@ -3698,8 +3698,11 @@ static switch_status_t voicemail_leave_main(switch_core_session_t *session, vm_p
 
                        switch_snprintf(duration_str, sizeof(duration_str), "%.2u:%.2u:%.2u", duration.hr, duration.min, duration.sec);
 
+                       switch_channel_set_variable(channel, "voicemail_account", id);
+                       switch_channel_set_variable(channel, "voicemail_domain", domain_name);
+                       switch_channel_set_variable(channel, "voicemail_file_path", file_path);
+                       switch_channel_set_variable(channel, "voicemail_read_flags", read_flags);
                        switch_channel_set_variable(channel, "voicemail_message_len", duration_str);
-
                } else {
                        switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Failed to deliver message\n");
                        TRY_CODE(switch_ivr_phrase_macro(session, VM_ACK_MACRO, "deleted", NULL, NULL));