[evolution-kolab] Adapt to CamelIMAPXServer API changes in 3.5.91.
- From: Matthew Barnes <mbarnes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-kolab] Adapt to CamelIMAPXServer API changes in 3.5.91.
- Date: Thu, 30 Aug 2012 21:08:24 +0000 (UTC)
commit 62141412d8b7a3a4e0a6394f03bd741e4d272cc1
Author: Matthew Barnes <mbarnes redhat com>
Date: Thu Aug 30 11:50:11 2012 -0400
Adapt to CamelIMAPXServer API changes in 3.5.91.
src/libekolab/camel-imapx-extd-server-acl.c | 4 ++++
src/libekolab/camel-imapx-extd-server-metadata.c | 21 ++++++++++++++++-----
2 files changed, 20 insertions(+), 5 deletions(-)
---
diff --git a/src/libekolab/camel-imapx-extd-server-acl.c b/src/libekolab/camel-imapx-extd-server-acl.c
index 46c3d17..1a58bcd 100644
--- a/src/libekolab/camel-imapx-extd-server-acl.c
+++ b/src/libekolab/camel-imapx-extd-server-acl.c
@@ -41,11 +41,13 @@
static gboolean
imapx_extd_server_untagged_acl (CamelIMAPXServer *is,
+ CamelIMAPXStream *stream,
GCancellable *cancellable,
GError **err);
static gboolean
imapx_extd_server_untagged_myrights (CamelIMAPXServer *is,
+ CamelIMAPXStream *stream,
GCancellable *cancellable,
GError **err);
@@ -67,6 +69,7 @@ static const CamelIMAPXUntaggedRespHandlerDesc desc_myrights = {
static gboolean
imapx_extd_server_untagged_acl (CamelIMAPXServer *is,
+ CamelIMAPXStream *stream,
GCancellable *cancellable,
GError **err)
{
@@ -82,6 +85,7 @@ imapx_extd_server_untagged_acl (CamelIMAPXServer *is,
static gboolean
imapx_extd_server_untagged_myrights (CamelIMAPXServer *is,
+ CamelIMAPXStream *stream,
GCancellable *cancellable,
GError **err)
{
diff --git a/src/libekolab/camel-imapx-extd-server-metadata.c b/src/libekolab/camel-imapx-extd-server-metadata.c
index 39ffa0a..160254e 100644
--- a/src/libekolab/camel-imapx-extd-server-metadata.c
+++ b/src/libekolab/camel-imapx-extd-server-metadata.c
@@ -39,6 +39,7 @@
static gboolean
imapx_extd_server_untagged_annotation (CamelIMAPXServer *is,
+ CamelIMAPXStream *stream,
GCancellable *cancellable,
GError **err);
@@ -53,21 +54,26 @@ static const CamelIMAPXUntaggedRespHandlerDesc desc_annotation = {
static gboolean
imapx_extd_server_untagged_annotation (CamelIMAPXServer *is,
+ CamelIMAPXStream *stream,
GCancellable *cancellable,
GError **err)
{
+ CamelIMAPXStore *store;
CamelIMAPXExtdStore *estore = NULL;
CamelImapxMetadata *md = NULL;
guint32 capa = 0;
guint32 capa_flag_id = 0;
GError *tmp_err = NULL;
gboolean parse_and_add_ok = FALSE;
+ gboolean success = FALSE;
g_assert (CAMEL_IS_IMAPX_SERVER (is));
/* cancellable may be NULL */
g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
- estore = CAMEL_IMAPX_EXTD_STORE (is->store);
+ store = camel_imapx_server_ref_store (is);
+
+ estore = CAMEL_IMAPX_EXTD_STORE (store);
/* capability check */
capa_flag_id =
@@ -79,22 +85,27 @@ imapx_extd_server_untagged_annotation (CamelIMAPXServer *is,
CAMEL_IMAPX_ERROR,
1, /* FIXME define and add a sensible code here */
_("Got ANNOTATION response but server did not advertise ANNOTATEMORE capability"));
- return FALSE;
+ goto exit;
}
md = camel_imapx_extd_store_get_md_table (estore);
parse_and_add_ok =
camel_imapx_metadata_add_from_server_response (md,
- is->stream,
+ stream,
cancellable,
&tmp_err);
if (! parse_and_add_ok) {
g_propagate_error (err, tmp_err);
- return FALSE;
+ goto exit;
}
- return TRUE;
+ success = TRUE;
+
+exit:
+ g_object_unref (store);
+
+ return success;
}
/*----------------------------------------------------------------------------*/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]