aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2008-08-28 15:31:43 +0800
committerMilan Crha <mcrha@src.gnome.org>2008-08-28 15:31:43 +0800
commitb693cbeb05a95fd893ef6053548c7aa7300c999a (patch)
treef99351959940575b4e7e273645208fb7a8359984
parent63bda84ccffbe899abdbefaa0eb476d2343134aa (diff)
downloadgsoc2013-evolution-b693cbeb05a95fd893ef6053548c7aa7300c999a.tar
gsoc2013-evolution-b693cbeb05a95fd893ef6053548c7aa7300c999a.tar.gz
gsoc2013-evolution-b693cbeb05a95fd893ef6053548c7aa7300c999a.tar.bz2
gsoc2013-evolution-b693cbeb05a95fd893ef6053548c7aa7300c999a.tar.lz
gsoc2013-evolution-b693cbeb05a95fd893ef6053548c7aa7300c999a.tar.xz
gsoc2013-evolution-b693cbeb05a95fd893ef6053548c7aa7300c999a.tar.zst
gsoc2013-evolution-b693cbeb05a95fd893ef6053548c7aa7300c999a.zip
** Fix for bug #509647
2008-08-28 Milan Crha <mcrha@redhat.com> ** Fix for bug #509647 * em-folder-utils.c: (emft_copy_folders__exec): * mail-ops.c: (fetch_mail_exec), (send_queue_exec): Do not expunge folder when something goes wrong. svn path=/trunk/; revision=36143
-rw-r--r--mail/ChangeLog8
-rw-r--r--mail/em-folder-utils.c2
-rw-r--r--mail/mail-ops.c8
3 files changed, 14 insertions, 4 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 855033b555..b90c11f8c7 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,11 @@
+2008-08-28 Milan Crha <mcrha@redhat.com>
+
+ ** Fix for bug #509647
+
+ * em-folder-utils.c: (emft_copy_folders__exec):
+ * mail-ops.c: (fetch_mail_exec), (send_queue_exec):
+ Do not expunge folder when something goes wrong.
+
2008-08-27 Philip Withnall <philip@tecnocode.co.uk>
** Fix for bug #534762
diff --git a/mail/em-folder-utils.c b/mail/em-folder-utils.c
index b1ec99f25e..1521d29a67 100644
--- a/mail/em-folder-utils.c
+++ b/mail/em-folder-utils.c
@@ -174,7 +174,7 @@ emft_copy_folders__exec (struct _EMCopyFolders *m)
camel_folder_transfer_messages_to (fromfolder, uids, tofolder, NULL, m->delete, &m->base.ex);
camel_folder_free_uids (fromfolder, uids);
- if (m->delete)
+ if (m->delete && !camel_exception_is_set (&m->base.ex))
camel_folder_sync(fromfolder, TRUE, NULL);
camel_object_unref (fromfolder);
diff --git a/mail/mail-ops.c b/mail/mail-ops.c
index 705e43898b..00eebd201a 100644
--- a/mail/mail-ops.c
+++ b/mail/mail-ops.c
@@ -337,7 +337,7 @@ fetch_mail_exec (struct _fetch_mail_msg *m)
}
}
- if (fm->delete || cache_uids) {
+ if ((fm->delete || cache_uids) && !camel_exception_is_set (&fm->base.ex)) {
/* expunge messages (downloaded so far) */
camel_folder_sync(folder, fm->delete, NULL);
}
@@ -772,8 +772,10 @@ send_queue_exec (struct _send_queue_msg *m)
camel_folder_free_uids (m->queue, uids);
g_ptr_array_free (send_uids, TRUE);
- camel_folder_sync (m->queue, TRUE, &ex);
- camel_exception_clear (&ex);
+ if (j <= 0 && !camel_exception_is_set (&m->base.ex)) {
+ camel_folder_sync (m->queue, TRUE, &ex);
+ camel_exception_clear (&ex);
+ }
if (sent_folder) {
camel_folder_sync (sent_folder, FALSE, &ex);