Changeset 3729

Show
Ignore:
Timestamp:
07/28/08 19:54:39
Author:
svillar
Message:
  • Ported a POP3 fix from trunk
Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • releases/modest/diablo-pe2/ChangeLog

    r3727 r3729  
     12008-07-28  Sergio Villar Senin  <svillar@igalia.com> 
     2 
     3        * libtinymail-camel/camel-lite/camel/providers/pop3/camel-pop3-folder.c: 
     4        do not mark as expunged those messages that could not be retrieved due 
     5        to the user canceled the request 
     6 
    172008-07-23  Sergio Villar Senin  <svillar@igalia.com> 
    28 
  • releases/modest/diablo-pe2/libtinymail-camel/camel-lite/camel/providers/pop3/camel-pop3-folder.c

    r3671 r3729  
    11701170                         * the user has a delete-mail finger  ... ) */ 
    11711171 
    1172                         CamelFolder *folder = (CamelFolder *) pop3_folder; 
    1173                         CamelMessageInfo *mi = camel_folder_summary_uid (folder->summary, uid); 
    1174                         if (mi) { 
    1175                                 CamelFolderChangeInfo *changes = camel_folder_change_info_new (); 
    1176                                 ((CamelMessageInfoBase*)mi)->flags |= CAMEL_MESSAGE_EXPUNGED; 
    1177                                 if (mi->uid) { 
    1178                                         camel_folder_change_info_remove_uid (changes, mi->uid); 
    1179                                         camel_object_trigger_event (CAMEL_OBJECT (folder), "folder_changed", changes); 
     1172                        if (camel_operation_cancel_check (NULL)) { 
     1173                                camel_exception_setv(ex, CAMEL_EXCEPTION_USER_CANCEL, 
     1174                                        "User canceled message retrieval"); 
     1175                        } else { 
     1176                                CamelFolder *folder = (CamelFolder *) pop3_folder; 
     1177                                CamelMessageInfo *mi = camel_folder_summary_uid (folder->summary, uid); 
     1178                                if (mi) { 
     1179                                        CamelFolderChangeInfo *changes = camel_folder_change_info_new (); 
     1180                                        ((CamelMessageInfoBase*)mi)->flags |= CAMEL_MESSAGE_EXPUNGED; 
     1181                                        if (mi->uid) { 
     1182                                                camel_folder_change_info_remove_uid (changes, mi->uid); 
     1183                                                camel_object_trigger_event (CAMEL_OBJECT (folder), "folder_changed", changes); 
     1184                                        } 
     1185                                        camel_folder_summary_remove (folder->summary, mi); 
     1186                                        camel_folder_change_info_free (changes); 
     1187                                        camel_message_info_free (mi); 
    11801188                                } 
    1181                                 camel_folder_summary_remove (folder->summary, mi); 
    1182                                 camel_folder_change_info_free (changes); 
    1183                                 camel_message_info_free (mi); 
     1189 
     1190                                camel_exception_setv (ex, CAMEL_EXCEPTION_FOLDER_UID_NOT_AVAILABLE, 
     1191                                      "Message with UID %s is not currently available on the POP server. " 
     1192                                      "If you have a web E-mail account with POP access, make sure " 
     1193                                      "that you select to export all E-mails over POP for mail, " 
     1194                                      "the ones that have already been downloaded too. Also verify " 
     1195                                      "whether other E-mail clients that use the account are not " 
     1196                                      "configured to automatically delete E-mails from the POP server." , 
     1197                                      uid); 
    11841198                        } 
    1185  
    1186                         camel_exception_setv (ex, CAMEL_EXCEPTION_FOLDER_UID_NOT_AVAILABLE, 
    1187                           "Message with UID %s is not currently available on the POP server. " 
    1188                           "If you have a web E-mail account with POP access, make sure " 
    1189                           "that you select to export all E-mails over POP for mail, " 
    1190                           "the ones that have already been downloaded too. Also verify " 
    1191                           "whether other E-mail clients that use the account are not " 
    1192                           "configured to automatically delete E-mails from the POP server." , 
    1193                           uid); 
    11941199 
    11951200                        g_static_rec_mutex_unlock (pop3_store->uidl_lock);