[asterisk-bugs] [Asterisk 0017871]: [patch] IMAP with maildir formats do not handle greetings correctly

Asterisk Bug Tracker noreply at bugs.digium.com
Wed Apr 13 14:52:16 CDT 2011


A NOTE has been added to this issue. 
====================================================================== 
https://issues.asterisk.org/view.php?id=17871 
====================================================================== 
Reported By:                edhorton
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   17871
Category:                   Applications/app_voicemail/IMAP
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     acknowledged
Asterisk Version:           1.6.2.11 
JIRA:                       SWP-2055 
Regression:                 No 
Reviewboard Link:            
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Request Review:              
====================================================================== 
Date Submitted:             2010-08-16 12:01 CDT
Last Modified:              2011-04-13 14:52 CDT
====================================================================== 
Summary:                    [patch] IMAP with maildir formats do not handle
greetings correctly
Description: 
Asterisk 1.6.2.11 with dovecot imap server and greetings stored in an IMAP
folder work correctly when MBOX format is used.

If the same settup is used, but maildir format is defined in dovecot.conf,
voicemail messages work correctly but Asterisk will always store the
greetings in the INBOX directory rather than the correct folder as defined
by the "greetingfolder" variable.  For playing greetings, it does fetch
from the "greeting" folder directory, so if the messages are manually moved
to that folder, Asterisk serves up the correct greetings.

But if a greeting is already resident in the "greeting" folder location,
the corresponding greeting is removed when a new greeting is recorded. 
This leaves the new greeting in INBOX and the old one removed from
"greetingfolder".

Again, when playing a greeting, Asterisk correcly fetches the greeting
from the "greetingfolder" location.  It will not fetch from INBOX if this
variable is set.
====================================================================== 

---------------------------------------------------------------------- 
 (0133738) edhorton (reporter) - 2011-04-13 14:52
 https://issues.asterisk.org/view.php?id=17871#c133738 
---------------------------------------------------------------------- 
I tried the patch logic on 1.8.3.2 but the logic seems incorrect.  If
imapgreetings = yes, then all voicemail messages are store in
greetingfolder since the if statement fails.  I changed to the following
code and it seems correct now.  If msgnum >= 0 then box is left as
NEW_FOLDER.  Sorry I didn't make a patch since I was not in the same
version. 

        /* Back out early if this is a greeting and we don't want to store
greetings in IMAP */
        if (msgnum < 0 ) {
           if (!imapgreetings) {
                return 0;
           } else {
                box = GREETINGS_FOLDER;
           }
        } 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2011-04-13 14:52 edhorton       Note Added: 0133738                          
======================================================================




More information about the asterisk-bugs mailing list