[asterisk-commits] trunk - r7225 in /trunk: ChangeLog UPGRADE.txt apps/app_voicemail.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Tue Nov 29 21:35:25 CST 2005


Author: twisted
Date: Tue Nov 29 21:35:24 2005
New Revision: 7225

URL: http://svn.digium.com/view/asterisk?rev=7225&view=rev
Log:
issue #5887

Modified:
    trunk/ChangeLog
    trunk/UPGRADE.txt
    trunk/apps/app_voicemail.c

Modified: trunk/ChangeLog
URL: http://svn.digium.com/view/asterisk/trunk/ChangeLog?rev=7225&r1=7224&r2=7225&view=diff
==============================================================================
--- trunk/ChangeLog (original)
+++ trunk/ChangeLog Tue Nov 29 21:35:24 2005
@@ -1,3 +1,7 @@
+2005-11-29  Josh Roberson <josh at asteriasgi.com>
+	
+	* apps/app_voicemail.c: Only look in 'default' context when no context defined to VoiceMailMain(). (issue #5887)
+
 2005-11-25  Russell Bryant  <russell at digium.com>
 
 	* apps/app_dial.c: Properly duplicate the string for ANI (issue #5850)

Modified: trunk/UPGRADE.txt
URL: http://svn.digium.com/view/asterisk/trunk/UPGRADE.txt?rev=7225&r1=7224&r2=7225&view=diff
==============================================================================
--- trunk/UPGRADE.txt (original)
+++ trunk/UPGRADE.txt Tue Nov 29 21:35:24 2005
@@ -130,6 +130,10 @@
   mailbox. This greeting can be recorded by using option 4 in the
   'mailbox options' menu, and 'change your password' option has been
   moved to option 5.
+
+* The application VoiceMailMain now only matches the 'default' context if
+  none is specified in the arguments.  (This was the previously 
+  documented behavior, however, we didn't follow that behavior.)
 
 Queues:
 

Modified: trunk/apps/app_voicemail.c
URL: http://svn.digium.com/view/asterisk/trunk/apps/app_voicemail.c?rev=7225&r1=7224&r2=7225&view=diff
==============================================================================
--- trunk/apps/app_voicemail.c (original)
+++ trunk/apps/app_voicemail.c Tue Nov 29 21:35:24 2005
@@ -573,8 +573,12 @@
 	struct ast_vm_user *vmu=NULL, *cur;
 	ast_mutex_lock(&vmlock);
 	cur = users;
+
+	if (!context)
+		context = "default";
+
 	while (cur) {
-		if ((!context || !strcasecmp(context, cur->context)) &&
+		if ((!strcasecmp(context, cur->context)) &&
 			(!strcasecmp(mailbox, cur->mailbox)))
 				break;
 		cur=cur->next;
@@ -4985,7 +4989,7 @@
 			valid++;
 		else {
 			if (option_verbose > 2)
-				ast_verbose( VERBOSE_PREFIX_3 "Incorrect password '%s' for user '%s' (context = %s)\n", password, mailbox, context ? context : "<any>");
+				ast_verbose( VERBOSE_PREFIX_3 "Incorrect password '%s' for user '%s' (context = %s)\n", password, mailbox, context ? context : "default");
 			if (!ast_strlen_zero(prefix))
 				mailbox[0] = '\0';
 		}



More information about the asterisk-commits mailing list