[evolution] e_mail_config_notebook_commit: Skip non-writable sources.



commit af493cae450d3b0d42d0806bd9b728af15b67270
Author: Matthew Barnes <mbarnes redhat com>
Date:   Sat Mar 9 08:44:37 2013 -0500

    e_mail_config_notebook_commit: Skip non-writable sources.
    
    In some cases the collection source is non-writable but its child
    sources _are_ writable.  In that case, the one non-writable source
    causes the whole operation to fail.  Commit only writable sources.

 mail/e-mail-config-notebook.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/mail/e-mail-config-notebook.c b/mail/e-mail-config-notebook.c
index fd43b20..bd7f548 100644
--- a/mail/e-mail-config-notebook.c
+++ b/mail/e-mail-config-notebook.c
@@ -807,18 +807,18 @@ e_mail_config_notebook_commit (EMailConfigNotebook *notebook,
 
        /* Queue the collection data source if one is defined. */
        source = e_mail_config_notebook_get_collection_source (notebook);
-       if (source != NULL)
+       if (source != NULL && e_source_get_writable (source))
                g_queue_push_tail (source_queue, g_object_ref (source));
 
        /* Queue the mail-related data sources for the account. */
        source = e_mail_config_notebook_get_account_source (notebook);
-       if (source != NULL)
+       if (source != NULL && e_source_get_writable (source))
                g_queue_push_tail (source_queue, g_object_ref (source));
        source = e_mail_config_notebook_get_identity_source (notebook);
-       if (source != NULL)
+       if (source != NULL && e_source_get_writable (source))
                g_queue_push_tail (source_queue, g_object_ref (source));
        source = e_mail_config_notebook_get_transport_source (notebook);
-       if (source != NULL)
+       if (source != NULL && e_source_get_writable (source))
                g_queue_push_tail (source_queue, g_object_ref (source));
 
        list = gtk_container_get_children (GTK_CONTAINER (notebook));


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]