[asterisk-dev] [Code Review] Missing new-message notification for urgent messages

Tilghman Lesher tlesher at digium.com
Tue Jan 12 17:57:06 CST 2010


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/444/#review1359
-----------------------------------------------------------

Ship it!


- Tilghman


On 2009-12-08 13:25:07, tomo1657 wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/444/
> -----------------------------------------------------------
> 
> (Updated 2009-12-08 13:25:07)
> 
> 
> Review request for Asterisk Developers.
> 
> 
> Summary
> -------
> 
> I apologize if I'm not supposed to post here, please remove if that's the case.
> 
> Review request for issue 0015654.
> 
> Problem 1: notify_new_message() only counts and attaches new messages which are in INBOX, not Urgent, using regular file system storage.
> 
> Problem 2: By moving urgent messages to Urgent before notify_new_message(), the MWI externnotify and email attachment in the function don't work, but by moving urgent messages to Urgent after notify_new_message(), the mail count in the function will be wrong (counts the urgent message as new, non-urgent).
> 
> In IMAP this is not an issue because new and urgent messages are both in INBOX.
> 
> The fixes made in this patch are:
> 
> 1) notify_new_message() checks the flag argument to see if the new message is an Urgent message. If so, it uses "Urgent" folder for "todir" instead of "INBOX".
> 
> 2) When a message is moved to Urgent folder, the "fn" is updated to "dfn" (Urgent folder path), and "msgnum" is updated to "x" (Message number in Urgent folder) so that the correct attachment is sent from the Urgent folder instead of trying to find a non-existent message in INBOX.
> 
> 3) The comment in the section "Created an Urgent message, moving file from %s to %s" wasn't useful because sfn and dfn weren't populated. I moved it down a few lines.
> 
> To recreate issue:
> 
> 1) Enable email delivery, set up externnotify path
> 2) leave an urgent, new message to an empty mailbox using file system storage
> 3) The email delivery and extennotify are not triggered since the Urgent message count is not being counted correctly
> 
> 
> This addresses bug 0015654.
>     https://issues.asterisk.org/view.php?id=0015654
> 
> 
> Diffs
> -----
> 
>   /trunk/apps/app_voicemail.c 233576 
> 
> Diff: https://reviewboard.asterisk.org/r/444/diff
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> tomo1657
> 
>




More information about the asterisk-dev mailing list