[evolution-data-server/gnome-2-30] Don't bother checking for is->cinfo being NULL. It can never happen now.
- From: David Woodhouse <dwmw2 src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-data-server/gnome-2-30] Don't bother checking for is->cinfo being NULL. It can never happen now.
- Date: Sat, 31 Jul 2010 15:27:45 +0000 (UTC)
commit 1525fa864c9dd6d3c88e3a40e135740d0b1bd23f
Author: David Woodhouse <David Woodhouse intel com>
Date: Thu Jun 24 11:12:02 2010 +0100
Don't bother checking for is->cinfo being NULL. It can never happen now.
Famous last words, I know...
(cherry picked from commit 7e0e64e76a0771fd6681d21fc63ce97251410e88)
(With a couple more in camel-imap-server.c which I had slipped in during
merges to gnome-2-30 branch)
camel/providers/imapx/camel-imapx-server.c | 13 +++++++------
1 files changed, 7 insertions(+), 6 deletions(-)
---
diff --git a/camel/providers/imapx/camel-imapx-server.c b/camel/providers/imapx/camel-imapx-server.c
index fd87c67..02887ab 100644
--- a/camel/providers/imapx/camel-imapx-server.c
+++ b/camel/providers/imapx/camel-imapx-server.c
@@ -502,7 +502,7 @@ imapx_command_add_part(CamelIMAPXCommand *ic, camel_imapx_command_part_t type, g
}
if (type & CAMEL_IMAPX_COMMAND_LITERAL_PLUS) {
- if (ic->is->cinfo && ic->is->cinfo->capa & IMAPX_CAPABILITY_LITERALPLUS) {
+ if (ic->is->cinfo->capa & IMAPX_CAPABILITY_LITERALPLUS) {
camel_stream_printf((CamelStream *)ic->mem, "{%u+}", ob_size);
} else {
type &= ~CAMEL_IMAPX_COMMAND_LITERAL_PLUS;
@@ -1598,10 +1598,11 @@ imapx_untagged(CamelIMAPXServer *imap, CamelException *ex)
break;
case IMAPX_CAPABILITY:
if (sinfo->u.cinfo) {
- if (imap->cinfo)
- imapx_free_capability(imap->cinfo);
+ struct _capability_info *cinfo = imap->cinfo;
imap->cinfo = sinfo->u.cinfo;
sinfo->u.cinfo = NULL;
+ if (cinfo)
+ imapx_free_capability(cinfo);
c(printf("got capability flags %08x\n", imap->cinfo->capa));
}
break;
@@ -2219,7 +2220,7 @@ imapx_in_idle (CamelIMAPXServer *is)
static gboolean
imapx_idle_supported (CamelIMAPXServer *is)
{
- return (is->cinfo && is->cinfo->capa & IMAPX_CAPABILITY_IDLE && is->use_idle);
+ return (is->cinfo->capa & IMAPX_CAPABILITY_IDLE && is->use_idle);
}
// end IDLE
@@ -2712,7 +2713,7 @@ imapx_reconnect (CamelIMAPXServer *is, CamelException *ex)
goto preauthed;
if (!authtype && service->url->authmech) {
- if (is->cinfo && !g_hash_table_lookup (is->cinfo->auth_types, service->url->authmech)) {
+ if (!g_hash_table_lookup (is->cinfo->auth_types, service->url->authmech)) {
camel_exception_setv (
ex, CAMEL_EXCEPTION_SERVICE_CANT_AUTHENTICATE,
_("IMAP server %s does not support requested "
@@ -3638,7 +3639,7 @@ imapx_job_refresh_info_start (CamelIMAPXServer *is, CamelIMAPXJob *job)
}
}
} else {
- if (is->cinfo && is->cinfo->capa & IMAPX_CAPABILITY_CONDSTORE)
+ if (is->cinfo->capa & IMAPX_CAPABILITY_CONDSTORE)
ic = camel_imapx_command_new (is, "STATUS", NULL, "STATUS %f (MESSAGES UNSEEN UIDNEXT HIGHESTMODSEQ)", folder);
else
ic = camel_imapx_command_new (is, "STATUS", NULL, "STATUS %f (MESSAGES UNSEEN UIDNEXT)", folder);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]