aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2013-12-11 04:02:42 +0800
committerMatthew Barnes <mbarnes@redhat.com>2013-12-11 04:02:42 +0800
commit30920a80243aae0a5839c805e8993f77e9899854 (patch)
treee0f59f24e0f2bc7169ba6a3401e13782b653fa60
parent8cb0dc0d4bb6e85fe0000a96f661d15e9bfa43a9 (diff)
downloadgsoc2013-evolution-30920a80243aae0a5839c805e8993f77e9899854.tar
gsoc2013-evolution-30920a80243aae0a5839c805e8993f77e9899854.tar.gz
gsoc2013-evolution-30920a80243aae0a5839c805e8993f77e9899854.tar.bz2
gsoc2013-evolution-30920a80243aae0a5839c805e8993f77e9899854.tar.lz
gsoc2013-evolution-30920a80243aae0a5839c805e8993f77e9899854.tar.xz
gsoc2013-evolution-30920a80243aae0a5839c805e8993f77e9899854.tar.zst
gsoc2013-evolution-30920a80243aae0a5839c805e8993f77e9899854.zip
MailFolderCache: Remove some nuisance runtime warnings.
When renaming a folder, don't warn if the GalView files for the folder don't exist (errno == ENOENT). It may be the folder was never viewed.
-rw-r--r--libemail-engine/mail-folder-cache.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libemail-engine/mail-folder-cache.c b/libemail-engine/mail-folder-cache.c
index bcf74bb0af..2faaed3468 100644
--- a/libemail-engine/mail-folder-cache.c
+++ b/libemail-engine/mail-folder-cache.c
@@ -1155,7 +1155,7 @@ rename_folders (MailFolderCache *cache,
e_filename_make_safe (newuri);
oldfile = g_strdup_printf ("%s/custom_view-%s.xml", config_dir, olduri);
newfile = g_strdup_printf ("%s/custom_view-%s.xml", config_dir, newuri);
- if (g_rename (oldfile, newfile) == -1) {
+ if (g_rename (oldfile, newfile) == -1 && errno != ENOENT) {
g_warning (
"%s: Failed to rename '%s' to '%s': %s", G_STRFUNC,
oldfile, newfile, g_strerror (errno));
@@ -1164,7 +1164,7 @@ rename_folders (MailFolderCache *cache,
g_free (newfile);
oldfile = g_strdup_printf ("%s/current_view-%s.xml", config_dir, olduri);
newfile = g_strdup_printf ("%s/current_view-%s.xml", config_dir, newuri);
- if (g_rename (oldfile, newfile) == -1) {
+ if (g_rename (oldfile, newfile) == -1 && errno != ENOENT) {
g_warning (
"%s: Failed to rename '%s' to '%s': %s", G_STRFUNC,
oldfile, newfile, g_strerror (errno));