[Home]

Summary:ASTERISK-08795: [patch] poor handling of dropped IMAP connections
Reporter:Ben Smithurst (bsmithurst)Labels:
Date Opened:2007-02-13 11:16:52.000-0600Date Closed:2007-06-30 09:20:03
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Applications/app_voicemail
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) imapdrop.patch
Description:The IMAP code does not appear to handle the case very well where the IMAP connection is dropped.  This can lead to errors such as the following when leaving a message:

[Feb  6 11:29:16] ERROR[7531] app_voicemail.c: IMAP Error: [CLOSED] IMAP connection broken (server response)
[Feb  6 11:29:16] ERROR[7531] app_voicemail.c: IMAP Error: [CLOSED] IMAP connection lost
[Feb  6 11:29:16] ERROR[7531] app_voicemail.c: IMAP Error: [CLOSED] IMAP connection lost

I think it is just necessary to call initstream in a couple of places which does a ping on the connection to check it is still alive.

The attached patch appears to fix the issue in 1.4.0, however the patch does not apply to trunk.  I have checked the trunk code and it looks like a very similar patch would work, but the code is just slightly different.

If need be I can create a patch for trunk and test it, however I may not be able to do that immediately since we are having a few problems with our development server at the moment. :-(
Comments:By: Joshua C. Colp (jcolp) 2007-02-20 18:14:24.000-0600

Fixed in 1.4 as of revision 55741 and trunk as of revision 55748. Thanks!