aboutsummaryrefslogtreecommitdiffstats
path: root/mail/mail-local.c
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2002-04-18 04:00:39 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2002-04-18 04:00:39 +0800
commitd89c3d0a9c4ea8fc31cc7f980df48669511ccca3 (patch)
tree8f167018383c7427ddfd72abc27d03e9ca6764c2 /mail/mail-local.c
parent822505f93b2211eb209c7644156858b7bc83ef50 (diff)
downloadgsoc2013-evolution-d89c3d0a9c4ea8fc31cc7f980df48669511ccca3.tar.gz
gsoc2013-evolution-d89c3d0a9c4ea8fc31cc7f980df48669511ccca3.tar.zst
gsoc2013-evolution-d89c3d0a9c4ea8fc31cc7f980df48669511ccca3.zip
Just use g_basename. (mlf_finalize): Free the real_path.
2002-04-17 Jeffrey Stedfast <fejj@ximian.com> * mail-local.c (mail_local_folder_construct): Just use g_basename. (mlf_finalize): Free the real_path. * folder-browser.c (on_right_click): Unref the GdkGC so we don't leak it. svn path=/trunk/; revision=16493
Diffstat (limited to 'mail/mail-local.c')
-rw-r--r--mail/mail-local.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/mail/mail-local.c b/mail/mail-local.c
index 1493866ba5..a90d4ae15f 100644
--- a/mail/mail-local.c
+++ b/mail/mail-local.c
@@ -555,6 +555,8 @@ mlf_finalize (CamelObject *obj)
free_metainfo(mlf->meta);
+ g_free (mlf->real_path);
+
#ifdef ENABLE_THREADS
g_mutex_free (mlf->real_folder_lock);
#endif
@@ -585,12 +587,9 @@ mail_local_folder_construct(MailLocalFolder *mlf, MailLocalStore *parent_store,
{
const char *name;
char *metapath;
-
- name = strrchr(full_name, '/');
- if (name == NULL)
- name = full_name;
- name = name + 1;
-
+
+ name = g_basename (full_name);
+
d(printf("constructing local folder: full = %s, name = %s\n", full_name, name));
camel_folder_construct(CAMEL_FOLDER (mlf), CAMEL_STORE(parent_store), full_name, name);