[Asterisk-cvs] asterisk/apps app_voicemail2.c,1.54,1.55

markster at lists.digium.com markster at lists.digium.com
Thu Oct 2 01:41:28 CDT 2003


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

Modified Files:
	app_voicemail2.c 
Log Message:
Increment message id number in e-mail


Index: app_voicemail2.c
===================================================================
RCS file: /usr/cvsroot/asterisk/apps/app_voicemail2.c,v
retrieving revision 1.54
retrieving revision 1.55
diff -u -d -r1.54 -r1.55
--- app_voicemail2.c	26 Sep 2003 22:03:10 -0000	1.54
+++ app_voicemail2.c	2 Oct 2003 06:42:39 -0000	1.55
@@ -154,7 +154,7 @@
 
 static char *emailbody = NULL;
 static int pbxskip = 0;
-static char fromstring[40];
+static char fromstring[100];
 static char emailtitle[100];
 
 STANDARD_LOCAL_USER;
@@ -504,9 +504,9 @@
 		}
 		else
 		if (pbxskip)
-			fprintf(p, "Subject: New message %d in mailbox %s\n", msgnum, mailbox);
+			fprintf(p, "Subject: New message %d in mailbox %s\n", msgnum + 1, mailbox);
 		else
-			fprintf(p, "Subject: [PBX]: New message %d in mailbox %s\n", msgnum, mailbox);
+			fprintf(p, "Subject: [PBX]: New message %d in mailbox %s\n", msgnum + 1, mailbox);
 		fprintf(p, "Message-ID: <Asterisk-%d-%s-%d@%s>\n", msgnum, mailbox, getpid(), host);
 		fprintf(p, "MIME-Version: 1.0\n");
 		if (attach_user_voicemail) {
@@ -544,11 +544,11 @@
 
 			"in mailbox %s from %s, on %s so you might\n"
 			"want to check it when you get a chance.  Thanks!\n\n\t\t\t\t--Asterisk\n\n", name, 
-			dur, msgnum, mailbox, (callerid ? callerid : "an unknown caller"), date);
+			dur, msgnum + 1, mailbox, (callerid ? callerid : "an unknown caller"), date);
 		}
 		if (attach_user_voicemail) {
 			fprintf(p, "--%s\n", bound);
-			fprintf(p, "Content-Type: audio/x-wav; name=\"msg%04d.%s\"\n", msgnum, format);
+			fprintf(p, "Content-Type: audio/x-wav; name=\"msg%04d.%s\"\n", msgnum + 1, format);
 			fprintf(p, "Content-Transfer-Encoding: BASE64\n");
 			fprintf(p, "Content-Description: Voicemail sound attachment.\n");
 			fprintf(p, "Content-Disposition: attachment; filename=\"msg%04d.%s\"\n\n", msgnum, format);




More information about the svn-commits mailing list