Package: release.debian.org
Severity: normal
User: release.debian....@packages.debian.org
Usertags: unblock

Hi release team,

I'm seeking approval to upload e-d-s with a backported fix for a bug that
makes IMAP shared folders completely unusable when syncing is enabled.

https://bugzilla.gnome.org/show_bug.cgi?id=743533 (reported by me).

The bug will unsubscribe any shared folder your account is subscribed to,
and in general will drop changes made to the folders. It is also known
to confuse evolution in general up to a point that it makes it unresponsive.

This is the upstream commit:
https://git.gnome.org/browse/evolution-data-server/commit/?id=c64b95c59e5774a6eb335805122fae5cd54f0bbf

Attached is the debdiff of the full update, which consists only of a
backported version of the above commit, plus changelog addition.

The fix has been in use internally in my company for over a month and no
regressions have been found.

unblock evolution-data-server/3.12.9~git20141128.5242b0-2+deb8u2

-- System Information:
Debian Release: 8.0
  APT prefers unstable
  APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 3.16.0-4-amd64 (SMP w/4 CPU cores)
Locale: LANG=ca_ES.UTF-8, LC_CTYPE=ca_ES.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
diff -Nru evolution-data-server-3.12.9~git20141128.5242b0/debian/changelog evolution-data-server-3.12.9~git20141128.5242b0/debian/changelog
--- evolution-data-server-3.12.9~git20141128.5242b0/debian/changelog	2015-01-30 00:57:21.000000000 +0100
+++ evolution-data-server-3.12.9~git20141128.5242b0/debian/changelog	2015-02-12 11:00:28.000000000 +0100
@@ -1,3 +1,10 @@
+evolution-data-server (3.12.9~git20141128.5242b0-2+deb8u2) UNRELEASED; urgency=medium
+
+  * d/p/05_imapx-Shared-folders-removed-folder-list-refresh.patch: Fix shared
+    IMAP folders disappearing in some situations.
+
+ -- Jordi Mallach <jo...@debian.org>  Thu, 12 Feb 2015 10:59:19 +0100
+
 evolution-data-server (3.12.9~git20141128.5242b0-2+deb8u1) unstable; urgency=medium
 
   * d/p/03_Use-after-free-gpg-verif.patch: Fix crash during GPG signature
diff -Nru evolution-data-server-3.12.9~git20141128.5242b0/debian/patches/03_Use-after-free-gpg-verif.patch evolution-data-server-3.12.9~git20141128.5242b0/debian/patches/03_Use-after-free-gpg-verif.patch
--- evolution-data-server-3.12.9~git20141128.5242b0/debian/patches/03_Use-after-free-gpg-verif.patch	2015-01-29 23:49:10.000000000 +0100
+++ evolution-data-server-3.12.9~git20141128.5242b0/debian/patches/03_Use-after-free-gpg-verif.patch	2015-02-12 12:19:19.000000000 +0100
@@ -4,11 +4,11 @@
 Subject: Bug 741434 - Use-after-free after error in GPG signature verification
 
 
-diff --git a/camel/camel-gpg-context.c b/camel/camel-gpg-context.c
-index 742e943..0b694a7 100644
---- a/camel/camel-gpg-context.c
-+++ b/camel/camel-gpg-context.c
-@@ -1888,6 +1888,7 @@ gpg_verify_sync (CamelCipherContext *context,
+Index: evolution-data-server-3.12.9~git20141128.5242b0/camel/camel-gpg-context.c
+===================================================================
+--- evolution-data-server-3.12.9~git20141128.5242b0.orig/camel/camel-gpg-context.c
++++ evolution-data-server-3.12.9~git20141128.5242b0/camel/camel-gpg-context.c
+@@ -1889,6 +1889,7 @@ gpg_verify_sync (CamelCipherContext *con
  
  	g_object_unref (filter);
  	g_object_unref (istream);
@@ -16,6 +16,3 @@
  
  	g_seekable_seek (G_SEEKABLE (canon_stream), 0, G_SEEK_SET, NULL, NULL);
  
--- 
-cgit v0.10.1
-
diff -Nru evolution-data-server-3.12.9~git20141128.5242b0/debian/patches/05_imapx-Shared-folders-removed-folder-list-refresh.patch evolution-data-server-3.12.9~git20141128.5242b0/debian/patches/05_imapx-Shared-folders-removed-folder-list-refresh.patch
--- evolution-data-server-3.12.9~git20141128.5242b0/debian/patches/05_imapx-Shared-folders-removed-folder-list-refresh.patch	1970-01-01 01:00:00.000000000 +0100
+++ evolution-data-server-3.12.9~git20141128.5242b0/debian/patches/05_imapx-Shared-folders-removed-folder-list-refresh.patch	2015-02-12 12:18:43.000000000 +0100
@@ -0,0 +1,77 @@
+From c64b95c59e5774a6eb335805122fae5cd54f0bbf Mon Sep 17 00:00:00 2001
+From: Milan Crha <mc...@redhat.com>
+Date: Wed, 11 Feb 2015 18:13:37 +0100
+Subject: Bug 743533 - [IMAPx] Shared folders removed on folder list refresh
+
+
+Index: evolution-data-server-3.12.9~git20141128.5242b0/camel/providers/imapx/camel-imapx-store.c
+===================================================================
+--- evolution-data-server-3.12.9~git20141128.5242b0.orig/camel/providers/imapx/camel-imapx-store.c
++++ evolution-data-server-3.12.9~git20141128.5242b0/camel/providers/imapx/camel-imapx-store.c
+@@ -1425,8 +1425,6 @@ sync_folders (CamelIMAPXStore *imapx_sto
+ {
+ 	CamelIMAPXServer *server;
+ 	GHashTable *folder_info_results;
+-	GPtrArray *array;
+-	guint ii;
+ 	gboolean success;
+ 
+ 	server = camel_imapx_store_ref_server (imapx_store, NULL, FALSE, cancellable, error);
+@@ -1486,48 +1484,6 @@ sync_folders (CamelIMAPXStore *imapx_sto
+ 		g_mutex_unlock (&imapx_store->priv->mailboxes_lock);
+ 	}
+ 
+-	array = camel_store_summary_array (imapx_store->summary);
+-
+-	for (ii = 0; ii < array->len; ii++) {
+-		CamelStoreInfo *si;
+-		CamelFolderInfo *fi;
+-		const gchar *mailbox_name;
+-		const gchar *si_path;
+-		gboolean pattern_match;
+-
+-		si = g_ptr_array_index (array, ii);
+-		si_path = camel_store_info_path (imapx_store->summary, si);
+-
+-		mailbox_name = ((CamelIMAPXStoreInfo *) si)->mailbox_name;
+-		if (mailbox_name == NULL || *mailbox_name == '\0')
+-			continue;
+-
+-		pattern_match =
+-			(root_folder_path == NULL) ||
+-			(*root_folder_path == '\0') ||
+-			(g_str_has_prefix (si_path, root_folder_path));
+-		if (!pattern_match)
+-			continue;
+-
+-		fi = g_hash_table_lookup (folder_info_results, mailbox_name);
+-
+-		if (fi == NULL) {
+-			gchar *dup_folder_path = g_strdup (si_path);
+-
+-			if (dup_folder_path != NULL) {
+-				/* Do not unsubscribe from it, it influences UI for non-subscribable folders */
+-				imapx_delete_folder_from_cache (
+-					imapx_store, dup_folder_path);
+-				g_free (dup_folder_path);
+-			} else {
+-				camel_store_summary_remove (
+-					imapx_store->summary, si);
+-			}
+-		}
+-	}
+-
+-	camel_store_summary_array_free (imapx_store->summary, array);
+-
+ exit:
+ 	g_hash_table_destroy (folder_info_results);
+ 
+@@ -1771,7 +1727,7 @@ imapx_store_get_folder_info_sync (CamelS
+ 	}
+ 
+ 	/* XXX I don't know why the SUBSCRIBED flag matters here. */
+-	if (!initial_setup && flags & CAMEL_STORE_FOLDER_INFO_SUBSCRIBED) {
++	if (!initial_setup && (flags & CAMEL_STORE_FOLDER_INFO_SUBSCRIBED) != 0) {
+ 		time_t time_since_last_refresh;
+ 
+ 		time_since_last_refresh =
diff -Nru evolution-data-server-3.12.9~git20141128.5242b0/debian/patches/series evolution-data-server-3.12.9~git20141128.5242b0/debian/patches/series
--- evolution-data-server-3.12.9~git20141128.5242b0/debian/patches/series	2015-01-30 00:09:42.000000000 +0100
+++ evolution-data-server-3.12.9~git20141128.5242b0/debian/patches/series	2015-02-12 10:57:14.000000000 +0100
@@ -1,3 +1,4 @@
 02_Only-export-symbols-starting-with-e.patch
 03_Use-after-free-gpg-verif.patch
 04_sqlite-Track-pending-sync-requests.patch
+05_imapx-Shared-folders-removed-folder-list-refresh.patch

Reply via email to