aboutsummaryrefslogtreecommitdiffstats
path: root/camel/camel-folder-pt-proxy.c
diff options
context:
space:
mode:
Diffstat (limited to 'camel/camel-folder-pt-proxy.c')
-rw-r--r--camel/camel-folder-pt-proxy.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/camel/camel-folder-pt-proxy.c b/camel/camel-folder-pt-proxy.c
index b87f19382d..e293e07d64 100644
--- a/camel/camel-folder-pt-proxy.c
+++ b/camel/camel-folder-pt-proxy.c
@@ -192,14 +192,18 @@ _op_exec_or_plan_for_exec (CamelFolderPtProxy *proxy_folder, CamelOp *op)
op_queue = proxy_folder->op_queue;
- if (op_queue->service_available) {
- op_queue->service_available = FALSE;
+ if (camel_op_queue_get_service_availability (op_queue)) {
+ camel_op_queue_set_service_availability (op_queue, FALSE);
pthread_create (&thread, NULL , (thread_call_func)(op->func), op->param);
+ camel_op_free (op);
+ } else {
+ camel_op_queue_push_op (op_queue, op);
}
}
+
/* folder->init_with_store implementation */
typedef struct {
@@ -258,7 +262,7 @@ _init_with_store (CamelFolder *folder, CamelStore *parent_store)
param->folder = folder;
param->parent_store = parent_store;
- op->func = async_init_with_store;
+ op->func = _async_init_with_store;
op->param = param;