aboutsummaryrefslogtreecommitdiffstats
path: root/camel
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2002-06-15 05:51:18 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2002-06-15 05:51:18 +0800
commit3cbdcff43de5d8a9c379c6f64b8f192b1532fffb (patch)
tree88056098bd5a00c96f667a216571762219c34599 /camel
parent1957762cbf5375928fd0fe3fedb3b63850425e9e (diff)
downloadgsoc2013-evolution-3cbdcff43de5d8a9c379c6f64b8f192b1532fffb.tar
gsoc2013-evolution-3cbdcff43de5d8a9c379c6f64b8f192b1532fffb.tar.gz
gsoc2013-evolution-3cbdcff43de5d8a9c379c6f64b8f192b1532fffb.tar.bz2
gsoc2013-evolution-3cbdcff43de5d8a9c379c6f64b8f192b1532fffb.tar.lz
gsoc2013-evolution-3cbdcff43de5d8a9c379c6f64b8f192b1532fffb.tar.xz
gsoc2013-evolution-3cbdcff43de5d8a9c379c6f64b8f192b1532fffb.tar.zst
gsoc2013-evolution-3cbdcff43de5d8a9c379c6f64b8f192b1532fffb.zip
Unlock the command_lock after each UID STORE command so that other
2002-06-14 Jeffrey Stedfast <fejj@ximian.com> * providers/imap/camel-imap-folder.c (imap_sync_online): Unlock the command_lock after each UID STORE command so that other (probably more important) threads can send their requests. svn path=/trunk/; revision=17188
Diffstat (limited to 'camel')
-rw-r--r--camel/ChangeLog4
-rw-r--r--camel/providers/imap/camel-imap-folder.c15
2 files changed, 14 insertions, 5 deletions
diff --git a/camel/ChangeLog b/camel/ChangeLog
index 221a5d9cc0..15d4d35705 100644
--- a/camel/ChangeLog
+++ b/camel/ChangeLog
@@ -1,5 +1,9 @@
2002-06-14 Jeffrey Stedfast <fejj@ximian.com>
+ * providers/imap/camel-imap-folder.c (imap_sync_online): Unlock
+ the command_lock after each UID STORE command so that other
+ (probably more important) threads can send their requests.
+
* camel-arg.c:
* camel-disco-diary.c:
* camel-index-control.c:
diff --git a/camel/providers/imap/camel-imap-folder.c b/camel/providers/imap/camel-imap-folder.c
index 1855ce2e8b..813a82ee89 100644
--- a/camel/providers/imap/camel-imap-folder.c
+++ b/camel/providers/imap/camel-imap-folder.c
@@ -732,8 +732,8 @@ imap_sync_online (CamelFolder *folder, CamelException *ex)
want to unset the previously set flags.*/
unset = !(info->flags & CAMEL_IMAP_SERVER_FLAGS);
- /* FIXME: since we don't know the previously set
- flags, if unset is TRUE then just unset all the flags? */
+ /* FIXME: since we don't know the previously set flags,
+ if unset is TRUE then just unset all the flags? */
flaglist = imap_create_flag_list (unset ? CAMEL_IMAP_SERVER_FLAGS : info->flags);
/* Note: get_matching() uses UID_SET_LIMIT to limit
@@ -771,10 +771,15 @@ imap_sync_online (CamelFolder *folder, CamelException *ex)
}
g_ptr_array_free (matches, TRUE);
- if (camel_exception_is_set (ex)) {
- CAMEL_IMAP_STORE_UNLOCK (store, command_lock);
+ /* We unlock here so that other threads can have a chance to grab the command_lock */
+ CAMEL_IMAP_STORE_UNLOCK (store, command_lock);
+
+ /* check for an exception */
+ if (camel_exception_is_set (ex))
return;
- }
+
+ /* Re-lock the command_lock */
+ CAMEL_IMAP_STORE_LOCK (store, command_lock);
}
/* Save the summary */