[Asterisk-cvs] asterisk say.c,1.16,1.17 sounds.txt,1.25,1.26

markster at lists.digium.com markster at lists.digium.com
Wed Apr 28 00:26:50 CDT 2004


Update of /usr/cvsroot/asterisk
In directory mongoose.digium.com:/tmp/cvs-serv7020

Modified Files:
	say.c sounds.txt 
Log Message:
Merge bug 1483 -- advanced voicemail options


Index: say.c
===================================================================
RCS file: /usr/cvsroot/asterisk/say.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -d -r1.16 -r1.17
--- say.c	20 Feb 2004 17:43:46 -0000	1.16
+++ say.c	28 Apr 2004 04:33:16 -0000	1.17
@@ -34,6 +34,7 @@
 	int num = 0;
 	int res = 0;
 	while(fn2[num] && !res) {
+		fn[0] = '\0';
 		switch (fn2[num]) {
 			case ('*'):
 				snprintf(fn, sizeof(fn), "digits/star");
@@ -42,12 +43,16 @@
 				snprintf(fn, sizeof(fn), "digits/pound");
 				break;
 			default:
-				snprintf(fn, sizeof(fn), "digits/%c", fn2[num]);
+				if((fn2[num] >= '0') && (fn2[num] <= '9')){ /* Must be in {0-9} */	 
+					snprintf(fn, sizeof(fn), "digits/%c", fn2[num]);
+				}
 			}
-		res = ast_streamfile(chan, fn, lang);
-		if (!res) 
-			res = ast_waitstream(chan, ints);
-		ast_stopstream(chan);
+		if(strlen(fn)){ /* if length == 0, then skip this digit as it is invalid */
+			res = ast_streamfile(chan, fn, lang);
+			if (!res) 
+				res = ast_waitstream(chan, ints);
+			ast_stopstream(chan);
+		}
 		num++;
 	}
 	return res;

Index: sounds.txt
===================================================================
RCS file: /usr/cvsroot/asterisk/sounds.txt,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -d -r1.25 -r1.26
--- sounds.txt	9 Apr 2004 00:15:34 -0000	1.25
+++ sounds.txt	28 Apr 2004 04:33:16 -0000	1.26
@@ -426,3 +426,53 @@
  message without prepending
 
 %vm-mailboxfull.gsm%sorry but the users mail box can't accept more messages
+
+%vm-tocancelmsg.gsm%press star to cancel this message
+
+%vm-from.gsm%from
+
+%vm-from-extension.gsm%from extension
+
+%vm-from-phonenumber.gsm%from phone number
+
+%vm-unknown-caller.gsm%from an unknown caller
+
+%vm-advopts.gsm%press 3 for advanced options
+
+%vm-toreply.gsm%press 1 to send a reply
+
+%vm-tocallback.gsm%press 2 to call the person who sent this message
+
+%vm-tohearenv.gsm%press 3 to hear the message envelope
+
+%vm-tomakecall.gsm%press 4 to place an outgoing call
+
+%vm-starmain.gsm%press star to return to the main menu
+
+%vm-dialout.gsm%please wait while i connect your call
+
+%vm-enter-num-to-call.gsm%please enter the number you wish to call
+
+%vm-then-pound.gsm%then press pound
+
+%vm-star-cancel.gsm%press star to cancel
+
+%vm-num-i-have.gsm%the number i have is
+
+%vm-tocallnum.gsm%press 1 to call this number
+
+%vm-calldiffnum.gsm%press 2 to enter a different number
+
+%vm-nonumber.gsm%i'm afraid i don't know who sent this message
+
+%vm-toenternumber.gsm%press 1 to enter a number
+
+%vm-nobox.gsm%you cannot reply to this message because the sender does not have a mailbox
+
+%vm-review.gsm%press 1 to accept this recording press 2 to listen to it press 3 to rerecord your message
+
+%vm-torerecord.gsm%press 3 to rerecord your message
+
+%vm-reachoper.gsm%press 0 to reach an operator
+
+%vm-tooshort.gsm%your message is too short 




More information about the svn-commits mailing list