[evolution-data-server/gnome-40] I#328 - IMAPx: LIST-STATUS is not an extension of the LIST-EXTENDED
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-data-server/gnome-40] I#328 - IMAPx: LIST-STATUS is not an extension of the LIST-EXTENDED
- Date: Thu, 22 Apr 2021 12:48:50 +0000 (UTC)
commit ff8e5e7dc0faf0636ac3833542d37c92bfc0ba47
Author: Milan Crha <mcrha redhat com>
Date: Thu Apr 22 14:45:47 2021 +0200
I#328 - IMAPx: LIST-STATUS is not an extension of the LIST-EXTENDED
Closes https://gitlab.gnome.org/GNOME/evolution-data-server/-/issues/328
src/camel/providers/imapx/camel-imapx-server.c | 8 +++++++-
src/camel/providers/imapx/camel-imapx-utils.c | 7 -------
2 files changed, 7 insertions(+), 8 deletions(-)
---
diff --git a/src/camel/providers/imapx/camel-imapx-server.c b/src/camel/providers/imapx/camel-imapx-server.c
index 060b1274b..1f14cb7c5 100644
--- a/src/camel/providers/imapx/camel-imapx-server.c
+++ b/src/camel/providers/imapx/camel-imapx-server.c
@@ -601,6 +601,12 @@ imapx_server_stash_command_arguments (CamelIMAPXServer *is)
if (CAMEL_IMAPX_HAVE_CAPABILITY (is->priv->cinfo, SPECIAL_USE) || CAMEL_IMAPX_HAVE_CAPABILITY
(is->priv->cinfo, X_GM_EXT_1))
g_string_append_printf (buffer, " SPECIAL-USE");
is->priv->list_return_opts = g_string_free (buffer, FALSE);
+ } else if (!is->priv->is_broken_cyrus && CAMEL_IMAPX_HAVE_CAPABILITY (is->priv->cinfo, LIST_STATUS)) {
+ buffer = g_string_new ("");
+ g_string_append_printf (
+ buffer, "STATUS (%s)",
+ is->priv->status_data_items);
+ is->priv->list_return_opts = g_string_free (buffer, FALSE);
} else {
is->priv->list_return_opts = NULL;
}
@@ -6522,7 +6528,7 @@ camel_imapx_server_list_sync (CamelIMAPXServer *is,
camel_imapx_command_unref (ic);
- if (success && !is->priv->list_return_opts) {
+ if (success && (!is->priv->list_return_opts || CAMEL_IMAPX_LACK_CAPABILITY (is->priv->cinfo,
LIST_EXTENDED))) {
ic = camel_imapx_command_new (is, CAMEL_IMAPX_JOB_LSUB, "LSUB \"\" %s",
utf7_pattern ? utf7_pattern : in_pattern);
diff --git a/src/camel/providers/imapx/camel-imapx-utils.c b/src/camel/providers/imapx/camel-imapx-utils.c
index 141f083e2..9bd729b28 100644
--- a/src/camel/providers/imapx/camel-imapx-utils.c
+++ b/src/camel/providers/imapx/camel-imapx-utils.c
@@ -585,13 +585,6 @@ imapx_parse_capability (CamelIMAPXInputStream *stream,
stream, &token, &len, cancellable, &local_error);
}
- /* Some capabilities are extensions of other capabilities.
- * Make sure all prerequisite capability flags are present. */
-
- /* LIST-STATUS is an extension of LIST-EXTENDED. */
- if (CAMEL_IMAPX_HAVE_CAPABILITY (cinfo, LIST_STATUS))
- cinfo->capa |= imapx_lookup_capability ("LIST-EXTENDED");
-
if (local_error != NULL) {
g_propagate_error (error, local_error);
imapx_free_capability (cinfo);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]