diff options
author | Jeffrey Stedfast <fejj@ximian.com> | 2004-01-24 04:48:59 +0800 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2004-01-24 04:48:59 +0800 |
commit | af75cca70337d1c83723a513811696bfed80ef99 (patch) | |
tree | 3f75ef63739621fb129b0560085497500c07e57b /mail | |
parent | 481af7a34f4121fcc69f09cd5dbad44602681229 (diff) | |
download | gsoc2013-evolution-af75cca70337d1c83723a513811696bfed80ef99.tar gsoc2013-evolution-af75cca70337d1c83723a513811696bfed80ef99.tar.gz gsoc2013-evolution-af75cca70337d1c83723a513811696bfed80ef99.tar.bz2 gsoc2013-evolution-af75cca70337d1c83723a513811696bfed80ef99.tar.lz gsoc2013-evolution-af75cca70337d1c83723a513811696bfed80ef99.tar.xz gsoc2013-evolution-af75cca70337d1c83723a513811696bfed80ef99.tar.zst gsoc2013-evolution-af75cca70337d1c83723a513811696bfed80ef99.zip |
Handle where the file: url is roken (ie, points to a location out of the
2004-01-23 Jeffrey Stedfast <fejj@ximian.com>
* em-migrate.c (upgrade_xml_uris_1_4): Handle where the file: url
is roken (ie, points to a location out of the evolution
namespace).
svn path=/trunk/; revision=24388
Diffstat (limited to 'mail')
-rw-r--r-- | mail/ChangeLog | 6 | ||||
-rw-r--r-- | mail/em-migrate.c | 8 |
2 files changed, 13 insertions, 1 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog index 3e3848fb78..0075a5a909 100644 --- a/mail/ChangeLog +++ b/mail/ChangeLog @@ -1,3 +1,9 @@ +2004-01-23 Jeffrey Stedfast <fejj@ximian.com> + + * em-migrate.c (upgrade_xml_uris_1_4): Handle where the file: url + is roken (ie, points to a location out of the evolution + namespace). + 2004-01-23 Rodney Dawes <dobey@ximian.com> * em-folder-selector.c: Set the mnemonic widget for "Folder _name:" diff --git a/mail/em-migrate.c b/mail/em-migrate.c index 2961c049a1..6ef3a3acf6 100644 --- a/mail/em-migrate.c +++ b/mail/em-migrate.c @@ -1712,7 +1712,13 @@ upgrade_xml_uris_1_4 (const char *uri) camel_url_set_host (url, "local"); prefix = g_build_filename (g_get_home_dir (), "evolution", "local", NULL); - g_assert (strncmp (url->path, prefix, strlen (prefix)) == 0); + if (strncmp (url->path, prefix, strlen (prefix)) != 0) { + /* uri is busticated - user probably copied from another user's home directory */ + camel_url_free (url); + g_free (prefix); + + return g_strdup (uri); + } path = g_strdup (url->path + strlen (prefix)); g_free (prefix); |