diff options
author | Not Zed <NotZed@Ximian.com> | 2003-04-19 11:15:54 +0800 |
---|---|---|
committer | Michael Zucci <zucchi@src.gnome.org> | 2003-04-19 11:15:54 +0800 |
commit | 04ccbdd8e80cac98e26ecdf781101fedf748ac15 (patch) | |
tree | 706bd55d11891e3bb39e360a31a27233bb71f831 /camel/providers | |
parent | d68227cb50fd2dba42dbba0c843220f5dfc434f2 (diff) | |
download | gsoc2013-evolution-04ccbdd8e80cac98e26ecdf781101fedf748ac15.tar.gz gsoc2013-evolution-04ccbdd8e80cac98e26ecdf781101fedf748ac15.tar.zst gsoc2013-evolution-04ccbdd8e80cac98e26ecdf781101fedf748ac15.zip |
** for #40989
2003-04-17 Not Zed <NotZed@Ximian.com>
** for #40989
* camel-text-index.c (text_index_delete): delete the block
file/key file directly, not just its files.
* providers/local/camel-local-folder.c (local_delete): implement,
just delete the index file if it exists.
camel-store-delete-folder will delete other data (maybe it all
should be done here).
* camel-block-file.c (camel_key_file_finalise): keep lock around
decrementing key file use count.
(camel_key_file_delete): new function to delete the key file (&
close it off).
(key_file_use): if we've been deleted, always fail.
(camel_block_file_finalise): only close the file if its a valid
fd.
(block_file_use): if we've been deleted, always fail.
(camel_block_file_delete): delete the block file & close.
(struct _CamelBlockFilePrivate): fix the !ENABLE_THREADS case to
still compile this.
svn path=/trunk/; revision=20894
Diffstat (limited to 'camel/providers')
-rw-r--r-- | camel/providers/local/camel-local-folder.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/camel/providers/local/camel-local-folder.c b/camel/providers/local/camel-local-folder.c index c93f8b18c7..ca49071d2e 100644 --- a/camel/providers/local/camel-local-folder.c +++ b/camel/providers/local/camel-local-folder.c @@ -79,6 +79,7 @@ static GPtrArray *local_search_by_expression(CamelFolder *folder, const char *ex static GPtrArray *local_search_by_uids(CamelFolder *folder, const char *expression, GPtrArray *uids, CamelException *ex); static void local_search_free(CamelFolder *folder, GPtrArray * result); +static void local_delete(CamelFolder *folder); static void local_rename(CamelFolder *folder, const char *newname); static void local_finalize(CamelObject * object); @@ -104,6 +105,7 @@ camel_local_folder_class_init(CamelLocalFolderClass * camel_local_folder_class) camel_folder_class->search_by_uids = local_search_by_uids; camel_folder_class->search_free = local_search_free; + camel_folder_class->delete = local_delete; camel_folder_class->rename = local_rename; camel_local_folder_class->lock = local_lock; @@ -437,6 +439,16 @@ local_expunge(CamelFolder *folder, CamelException *ex) } static void +local_delete(CamelFolder *folder) +{ + CamelLocalFolder *lf = (CamelLocalFolder *)folder; + + camel_index_delete(lf->index); + + parent_class->delete(folder); +} + +static void local_rename(CamelFolder *folder, const char *newname) { CamelLocalFolder *lf = (CamelLocalFolder *)folder; |