Changeset 3652

Show
Ignore:
Timestamp:
05/12/08 11:03:41
Author:
svillar
Message:
  • Added a couple of missing unreasons
Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/ChangeLog

    r3651 r3652  
     12008-05-12  Sergio Villar Senin  <svillar@igalia.com> 
     2 
     3        * libtinymail-camel/tny-camel-send-queue.c: Add camel folder reason to 
     4        sentbox and outbox while sending, as we can get unreasons and have 
     5        then crash because the message cache is freed. (Based on a previous 
     6        patch by Dape) 
     7 
    182008-05-09  Jose Dapena Paz  <jdapena@igalia.com> 
    29 
  • trunk/libtinymail-camel/tny-camel-send-queue.c

    r3637 r3652  
    794794        g_object_unref (info->self); 
    795795 
    796  
    797796        if (TNY_IS_CAMEL_FOLDER (info->sentbox)) { 
    798797                TnyCamelFolderPriv *spriv = TNY_CAMEL_FOLDER_GET_PRIVATE (info->sentbox); 
     
    864863                        info->trans_account = (TnyTransportAccount *) g_object_ref (priv->trans_account); 
    865864 
     865                        if (TNY_IS_CAMEL_FOLDER (info->outbox)) { 
     866                                TnyCamelFolderPriv *opriv = TNY_CAMEL_FOLDER_GET_PRIVATE (info->outbox); 
     867                                _tny_camel_folder_reason (opriv); 
     868                        } 
    866869                        if (TNY_IS_CAMEL_FOLDER (info->sentbox)) { 
    867870                                TnyCamelFolderPriv *spriv = TNY_CAMEL_FOLDER_GET_PRIVATE (info->sentbox); 
     
    869872                        } 
    870873 
    871                         if (TNY_IS_CAMEL_FOLDER (info->outbox)) { 
    872                                 TnyCamelFolderPriv *opriv = TNY_CAMEL_FOLDER_GET_PRIVATE (info->outbox); 
    873                                 _tny_camel_folder_reason (opriv); 
     874                        emit_queue_control_signals (self, TNY_SEND_QUEUE_START); 
     875 
     876                        priv->thread = g_thread_create (thread_main, info, FALSE, NULL); 
     877 
     878                        if (priv->thread == NULL) { 
     879                                emit_queue_control_signals (self, TNY_SEND_QUEUE_STOP); 
     880                                if (TNY_IS_CAMEL_FOLDER (info->outbox)) { 
     881                                        TnyCamelFolderPriv *opriv = TNY_CAMEL_FOLDER_GET_PRIVATE (info->outbox); 
     882                                        _tny_camel_folder_unreason (opriv); 
     883                                } 
     884                                if (TNY_IS_CAMEL_FOLDER (info->sentbox)) { 
     885                                        TnyCamelFolderPriv *spriv = TNY_CAMEL_FOLDER_GET_PRIVATE (info->sentbox); 
     886                                        _tny_camel_folder_unreason (spriv); 
     887                                } 
    874888                        } 
    875  
    876                         emit_queue_control_signals (self, TNY_SEND_QUEUE_START); 
    877  
    878                         priv->thread = g_thread_create (thread_main, info, FALSE, NULL); 
    879  
    880                         if (priv->thread == NULL) 
    881                                 emit_queue_control_signals (self, TNY_SEND_QUEUE_STOP); 
    882889                } 
    883890        }