diff options
author | Not Zed <NotZed@Ximian.com> | 2002-07-24 10:33:26 +0800 |
---|---|---|
committer | Michael Zucci <zucchi@src.gnome.org> | 2002-07-24 10:33:26 +0800 |
commit | 816d869e701164cbb1cee524b1ed39b4f61f05ca (patch) | |
tree | 2ad834d700a6aa432c66067e579c9a764c24267d /camel/providers | |
parent | 1bddc83831d27affaeb2d53d6808c696cecb5021 (diff) | |
download | gsoc2013-evolution-816d869e701164cbb1cee524b1ed39b4f61f05ca.tar.gz gsoc2013-evolution-816d869e701164cbb1cee524b1ed39b4f61f05ca.tar.zst gsoc2013-evolution-816d869e701164cbb1cee524b1ed39b4f61f05ca.zip |
Duplicated the very much hack in imap_store_refresh_folders() to avoid a
2002-07-24 Not Zed <NotZed@Ximian.com>
* providers/imap/camel-imap-store.c (get_folder_info_online):
Duplicated the very much hack in imap_store_refresh_folders() to
avoid a deadlock in #27959. A decent fix has to wait for a
rewrite.
svn path=/trunk/; revision=17560
Diffstat (limited to 'camel/providers')
-rw-r--r-- | camel/providers/imap/camel-imap-store.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/camel/providers/imap/camel-imap-store.c b/camel/providers/imap/camel-imap-store.c index fbc6c39b31..2065b53007 100644 --- a/camel/providers/imap/camel-imap-store.c +++ b/camel/providers/imap/camel-imap-store.c @@ -767,6 +767,7 @@ copy_folder(char *key, CamelFolder *folder, GPtrArray *out) /* the alternative is to: make the camel folder->lock recursive (which should probably be done) or remove it from camel_folder_refresh_info, and use another locking mechanism */ +/* also see get_folder_info_online() for the same hack repeated */ static void imap_store_refresh_folders (CamelImapStore *store, CamelException *ex) { @@ -2013,7 +2014,9 @@ get_folder_info_online (CamelStore *store, const char *top, */ if (imap_store->current_folder && !strcmp (imap_store->current_folder->full_name, fi->full_name)) { - camel_folder_refresh_info (imap_store->current_folder, NULL); + /* we bypass the folder locking otherwise we can deadlock. we use the command lock for + any operations anyway so this is 'safe'. See comment above imap_store_refresh_folders() for info */ + CAMEL_FOLDER_CLASS (CAMEL_OBJECT_GET_CLASS(imap_store->current_folder))->refresh_info(imap_store->current_folder, ex); fi->unread_message_count = camel_folder_get_unread_message_count (imap_store->current_folder); } else fi->unread_message_count = get_folder_status (imap_store, fi->full_name, "UNSEEN"); |