[Freeswitch-svn] [commit] r9785 - freeswitch/trunk/src/mod/applications/mod_voicemail

Freeswitch SVN anthm at freeswitch.org
Thu Oct 2 11:13:54 EDT 2008


Author: anthm
Date: Thu Oct  2 11:13:53 2008
New Revision: 9785

Modified:
   freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c

Log:
add voicemail_alternate_greet_id var

Modified: freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c
==============================================================================
--- freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c	(original)
+++ freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c	Thu Oct  2 11:13:53 2008
@@ -2666,8 +2666,12 @@
 			TRY_CODE(switch_ivr_play_file(session, NULL, cbt.name_path, &args));
 		}
 		if (*buf == '\0') {
+			const char *read_id;
+			if (!(read_id = switch_channel_get_variable(channel, "voicemail_alternate_greet_id"))) {
+				read_id = id;
+			}
 			memset(buf, 0, sizeof(buf));
-			TRY_CODE(switch_ivr_phrase_macro(session, VM_PLAY_GREETING_MACRO, id, NULL, &args));
+			TRY_CODE(switch_ivr_phrase_macro(session, VM_PLAY_GREETING_MACRO, read_id, NULL, &args));
 		}
 	}
 



More information about the Freeswitch-svn mailing list