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

Bug#704730: unblock: evolution/3.4.4-3



On Fri, Apr 05, 2013 at 04:53:54PM +0100, Jonathan Wiltshire wrote:
>  patches/06_fix_mbox_to_maildir_conversion.patch | 1384 ++++++++++++++++++++++++
>  patches/series                                  |    1 
>  3 files changed, 1393 insertions(+)
> 
> Eugh :-( though I did not look at it in detail yet, just a glance.

There's quite some code in there, but not as much a diffstat appears to
say. Many functions have been moved to a new file, verbatim, and a new
function was added. This could have been tucked in the same file, but I
preferred using the original patch to minimise the risk of introducing
errors in the backports.

The in-patch diffstat turns out to be this:

 shell/Makefile.am           |    3 
 shell/e-migrate-base-dirs.c |  655 ++++++++++++++++++++++++++++++++++++++++++++
 shell/e-shell-migrate.c     |  637 ------------------------------------------
 shell/main.c                |   11 
 4 files changed, 667 insertions(+), 639 deletions(-)

And if I'm not mistaken, the new code boils down to this, plus a call:

+e_migrate_base_dirs (EShell *shell)
+{
+	const gchar *home_dir;
+	gchar *old_base_dir;
+
+	g_return_if_fail (E_IS_SHELL (shell));
+
+	/* XXX This blocks, but it's all just local file
+	 *     renames so it should be nearly instantaneous. */
+
+	home_dir = g_get_home_dir ();
+	old_base_dir = g_build_filename (home_dir, ".evolution", NULL);
+
+	/* Is there even anything to migrate? */
+	if (!g_file_test (old_base_dir, G_FILE_TEST_IS_DIR))
+		goto exit;
+
+	shell_xdg_migrate_cache_dir (shell, old_base_dir);
+	shell_xdg_migrate_config_dir (shell, old_base_dir);
+	shell_xdg_migrate_data_dir (shell, old_base_dir);
+
+	/* Try to remove the old base directory.  Good chance this will
+	 * fail on the first try, since Evolution puts stuff here too. */
+	g_rmdir (old_base_dir);
+
+exit:
+	g_free (old_base_dir);
+}

> Is it true to say that all evolution users dist-upgrading from Squeeze will
> hit this then? The two bugs referenced are severity:important, so normally
> I'd nack this request, but it sounds like they should be higher...

I'm not convinced it will affect all users as the theory says, otherwise
we would have heard of this much sooner. It might well be most of our evo
users just use IMAP accounts and avoid local data (count me on that
group), but we nevertheless got two bugs recently + the other guy who went
talk upstream directly; I agree they should have been serious.

> There's a work-around in #701603. It's not ideal (manual import of each
> folder), but would it be better to document that than bring this code
> change in?

Applying this workaround would make me so angry I'd go straight to
Thunderbird. :)

-- 
Jordi Mallach Pérez  --  Debian developer     http://www.debian.org/
jordi@sindominio.net     jordi@debian.org     http://www.sindominio.net/
GnuPG public key information available at http://oskuro.net/


Reply to: