[asterisk-commits] mjordan: branch certified-11.2 r382618 - in /certified/branches/11.2: ./ apps/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Mar 7 11:57:52 CST 2013


Author: mjordan
Date: Thu Mar  7 11:57:49 2013
New Revision: 382618

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=382618
Log:
Let vm_mailbox_snapshot combine "Urgent" when no folder is specified

r381835 fixed a bug in vm_mailbox_snapshot where combining INBOX and Old forgot
that Urgent also "counts" as new messages. This fixed the problem when any of
the three folders was specified and the combine option was used.

It missed the case where the folder isn't specified and we build a snapshot of
all folders. This patch corrects that.
........

Merged revisions 382617 from http://svn.asterisk.org/svn/asterisk/branches/11

Modified:
    certified/branches/11.2/   (props changed)
    certified/branches/11.2/apps/app_voicemail.c

Propchange: certified/branches/11.2/
------------------------------------------------------------------------------
--- branch-11-merged (original)
+++ branch-11-merged Thu Mar  7 11:57:49 2013
@@ -1,1 +1,1 @@
-/branches/11:378038,378121,378287,378321,378409-378411,378459,378582,378687,378690,378984,379513,379790,380465,380698,380869,380892,380894,380974,381306,381594,381613,381702,381737,382385,382390,382573
+/branches/11:378038,378121,378287,378321,378409-378411,378459,378582,378687,378690,378984,379513,379790,380465,380698,380869,380892,380894,380974,381306,381594,381613,381702,381737,382385,382390,382573,382617

Modified: certified/branches/11.2/apps/app_voicemail.c
URL: http://svnview.digium.com/svn/asterisk/certified/branches/11.2/apps/app_voicemail.c?view=diff&rev=382618&r1=382617&r2=382618
==============================================================================
--- certified/branches/11.2/apps/app_voicemail.c (original)
+++ certified/branches/11.2/apps/app_voicemail.c Thu Mar  7 11:57:49 2013
@@ -15018,10 +15018,12 @@
 		int combining_old = 0;
 		/* Assume we are combining folders if:
 		 *  - The current index is the old folder index OR
-		 *  - The current index is urgent and we were looking for INBOX OR
-		 *  - The current index is INBOX and we were looking for Urgent
+		 *  - The current index is urgent and we were looking for INBOX or all folders OR
+		 *  - The current index is INBOX and we were looking for Urgent or all folders
 		 */
-		if ((i == old_index || (i == urgent_index && this_index_only == inbox_index) || (i == inbox_index && this_index_only == urgent_index)) && (combine_INBOX_and_OLD)) {
+		if ((i == old_index ||
+			(i == urgent_index && (this_index_only == inbox_index || this_index_only == -1)) ||
+			(i == inbox_index && (this_index_only == urgent_index || this_index_only == -1))) && (combine_INBOX_and_OLD)) {
 			combining_old = 1;
 		}
 




More information about the asterisk-commits mailing list