diff options
author | Jeffrey Stedfast <fejj@ximian.com> | 2003-07-08 03:18:57 +0800 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2003-07-08 03:18:57 +0800 |
commit | 8bbe0f34af2bd9906012106d8ee27187f05b6a15 (patch) | |
tree | 5cfa51a91191b20ef2f1f765df6f99611041cae5 /camel/providers | |
parent | 26709642fa1a39108690aa5295e1726a0861c58c (diff) | |
download | gsoc2013-evolution-8bbe0f34af2bd9906012106d8ee27187f05b6a15.tar gsoc2013-evolution-8bbe0f34af2bd9906012106d8ee27187f05b6a15.tar.gz gsoc2013-evolution-8bbe0f34af2bd9906012106d8ee27187f05b6a15.tar.bz2 gsoc2013-evolution-8bbe0f34af2bd9906012106d8ee27187f05b6a15.tar.lz gsoc2013-evolution-8bbe0f34af2bd9906012106d8ee27187f05b6a15.tar.xz gsoc2013-evolution-8bbe0f34af2bd9906012106d8ee27187f05b6a15.tar.zst gsoc2013-evolution-8bbe0f34af2bd9906012106d8ee27187f05b6a15.zip |
Updated for string-utils namespace changes.
2003-07-07 Jeffrey Stedfast <fejj@ximian.com>
* camel-session.c (camel_session_init): Updated for string-utils
namespace changes.
* camel-provider.c: Updated for string-utils namespace changes.
* camel-mime-part.c (init_header_name_table): Updated for
string-utils namespace changes.
* camel-mime-message.c (camel_mime_message_class_init): Updated
for string-utils namespace changes.
(camel_mime_message_init): Same.
* camel-mime-filter-enriched.c
(camel_mime_filter_enriched_class_init): Updated for string-utils
namespace changes.
* camel-folder-summary.c (camel_folder_summary_init): Updated for
string-utils namespace changes.
* camel-string-utils.[c,h]: Renamed from string-utils.[c,h] and
also namespaced all functions.
svn path=/trunk/; revision=21751
Diffstat (limited to 'camel/providers')
-rw-r--r-- | camel/providers/imap/camel-imap-folder.c | 2 | ||||
-rw-r--r-- | camel/providers/imap/camel-imap-store-summary.c | 1 | ||||
-rw-r--r-- | camel/providers/imap/camel-imap-store.c | 21 | ||||
-rw-r--r-- | camel/providers/imap/camel-imap-utils.c | 2 | ||||
-rw-r--r-- | camel/providers/local/camel-local-folder.c | 3 | ||||
-rw-r--r-- | camel/providers/local/camel-maildir-folder.c | 3 | ||||
-rw-r--r-- | camel/providers/local/camel-mbox-folder.c | 3 | ||||
-rw-r--r-- | camel/providers/local/camel-mbox-summary.c | 2 | ||||
-rw-r--r-- | camel/providers/local/camel-mh-folder.c | 3 | ||||
-rw-r--r-- | camel/providers/local/camel-spool-folder.c | 3 | ||||
-rw-r--r-- | camel/providers/smtp/camel-smtp-transport.c | 1 |
11 files changed, 29 insertions, 15 deletions
diff --git a/camel/providers/imap/camel-imap-folder.c b/camel/providers/imap/camel-imap-folder.c index a3fbb9baf3..860ce7026f 100644 --- a/camel/providers/imap/camel-imap-folder.c +++ b/camel/providers/imap/camel-imap-folder.c @@ -66,8 +66,8 @@ #include "camel-stream-filter.h" #include "camel-stream-mem.h" #include "camel-stream.h" -#include "string-utils.h" #include "camel-private.h" +#include "camel-string-utils.h" #define d(x) diff --git a/camel/providers/imap/camel-imap-store-summary.c b/camel/providers/imap/camel-imap-store-summary.c index 305bbfc0cd..d08fd9b66d 100644 --- a/camel/providers/imap/camel-imap-store-summary.c +++ b/camel/providers/imap/camel-imap-store-summary.c @@ -32,7 +32,6 @@ #include "camel-file-utils.h" -#include "string-utils.h" #include "e-util/md5-utils.h" #include "e-util/e-memory.h" diff --git a/camel/providers/imap/camel-imap-store.c b/camel/providers/imap/camel-imap-store.c index f4ec3579c8..bcaef3b96f 100644 --- a/camel/providers/imap/camel-imap-store.c +++ b/camel/providers/imap/camel-imap-store.c @@ -57,7 +57,7 @@ #include "camel-url.h" #include "camel-sasl.h" #include "camel-utf8.h" -#include "string-utils.h" +#include "camel-string-utils.h" #include "camel-imap-private.h" #include "camel-private.h" @@ -579,6 +579,8 @@ connect_to_server (CamelService *service, int ssl_mode, int try_starttls, CamelE tcp_stream = camel_tcp_stream_raw_new (); #endif /* HAVE_SSL */ + printf ("trying to connect to %s:%d...", service->url->host, port); + ret = camel_tcp_stream_connect (CAMEL_TCP_STREAM (tcp_stream), h, port); camel_free_host (h); if (ret == -1) { @@ -590,11 +592,15 @@ connect_to_server (CamelService *service, int ssl_mode, int try_starttls, CamelE _("Could not connect to %s (port %d): %s"), service->url->host, port, g_strerror (errno)); + printf ("failed: %s\n", g_strerror (errno)); + camel_object_unref (CAMEL_OBJECT (tcp_stream)); return FALSE; } + printf ("connected..."); + store->ostream = tcp_stream; store->istream = camel_stream_buffer_new (tcp_stream, CAMEL_STREAM_BUFFER_READ); @@ -603,6 +609,8 @@ connect_to_server (CamelService *service, int ssl_mode, int try_starttls, CamelE /* Read the greeting, if any. FIXME: deal with PREAUTH */ if (camel_imap_store_readline (store, &buf, ex) < 0) { + printf ("failed when trying to read greeting: %s\n", g_strerror (errno)); + if (store->istream) { camel_object_unref (CAMEL_OBJECT (store->istream)); store->istream = NULL; @@ -614,12 +622,15 @@ connect_to_server (CamelService *service, int ssl_mode, int try_starttls, CamelE } store->connected = FALSE; + return FALSE; } g_free (buf); /* get the imap server capabilities */ if (!imap_get_capability (service, ex)) { + printf ("failed to get capabilities: %s\n", g_strerror (errno)); + if (store->istream) { camel_object_unref (CAMEL_OBJECT (store->istream)); store->istream = NULL; @@ -656,6 +667,8 @@ connect_to_server (CamelService *service, int ssl_mode, int try_starttls, CamelE } #endif /* HAVE_SSL */ + printf ("success\n"); + return TRUE; #ifdef HAVE_SSL @@ -666,6 +679,7 @@ connect_to_server (CamelService *service, int ssl_mode, int try_starttls, CamelE response = camel_imap_command (store, NULL, ex, "STARTTLS"); if (!response) { + printf ("STARTTLS command failed: %s\n", g_strerror (errno)); camel_object_unref (CAMEL_OBJECT (store->istream)); camel_object_unref (CAMEL_OBJECT (store->ostream)); store->istream = store->ostream = NULL; @@ -676,6 +690,7 @@ connect_to_server (CamelService *service, int ssl_mode, int try_starttls, CamelE /* Okay, now toggle SSL/TLS mode */ if (camel_tcp_stream_ssl_enable_ssl (CAMEL_TCP_STREAM_SSL (tcp_stream)) == -1) { + printf ("failed toggling into STARTTLS mode: %s\n", g_strerror (errno)); camel_exception_setv (ex, CAMEL_EXCEPTION_SYSTEM, _("Failed to connect to IMAP server %s in secure mode: %s"), service->url->host, _("SSL negotiations failed")); @@ -685,6 +700,8 @@ connect_to_server (CamelService *service, int ssl_mode, int try_starttls, CamelE /* rfc2595, section 4 states that after a successful STLS command, the client MUST discard prior CAPA responses */ if (!imap_get_capability (service, ex)) { + printf ("failed getting capabilities after STARTLS: %s\n", g_strerror (errno)); + if (store->istream) { camel_object_unref (CAMEL_OBJECT (store->istream)); store->istream = NULL; @@ -700,6 +717,8 @@ connect_to_server (CamelService *service, int ssl_mode, int try_starttls, CamelE return FALSE; } + printf ("success\n"); + return TRUE; exception: diff --git a/camel/providers/imap/camel-imap-utils.c b/camel/providers/imap/camel-imap-utils.c index 91b88a7ec4..26a085739f 100644 --- a/camel/providers/imap/camel-imap-utils.c +++ b/camel/providers/imap/camel-imap-utils.c @@ -35,7 +35,7 @@ #include "camel-imap-summary.h" #include "camel-imap-store.h" #include "camel-folder.h" -#include "string-utils.h" +#include "camel-string-utils.h" #include "camel-utf8.h" #define d(x) diff --git a/camel/providers/local/camel-local-folder.c b/camel/providers/local/camel-local-folder.c index 74c876f226..80a9a1f1e9 100644 --- a/camel/providers/local/camel-local-folder.c +++ b/camel/providers/local/camel-local-folder.c @@ -2,7 +2,7 @@ * * Authors: Michael Zucchi <notzed@ximian.com> * - * Copyright (C) 1999, 2000 Ximian Inc. + * Copyright (C) 1999, 2003 Ximian Inc. * * This program is free software; you can redistribute it and/or * modify it under the terms of version 2 of the GNU General Public @@ -39,7 +39,6 @@ #include "camel-local-folder.h" #include "camel-local-store.h" -#include "string-utils.h" #include "camel-stream-fs.h" #include "camel-local-summary.h" #include "camel-data-wrapper.h" diff --git a/camel/providers/local/camel-maildir-folder.c b/camel/providers/local/camel-maildir-folder.c index d3cbc490b5..eca07efbef 100644 --- a/camel/providers/local/camel-maildir-folder.c +++ b/camel/providers/local/camel-maildir-folder.c @@ -2,7 +2,7 @@ * * Authors: Michael Zucchi <notzed@ximian.com> * - * Copyright (C) 1999, 2000 Ximian Inc. + * Copyright (C) 1999, 2003 Ximian Inc. * * This program is free software; you can redistribute it and/or * modify it under the terms of version 2 of the GNU General Public @@ -34,7 +34,6 @@ #include "camel-maildir-folder.h" #include "camel-maildir-store.h" -#include "string-utils.h" #include "camel-stream-fs.h" #include "camel-maildir-summary.h" #include "camel-data-wrapper.h" diff --git a/camel/providers/local/camel-mbox-folder.c b/camel/providers/local/camel-mbox-folder.c index f5332dc140..942610d5a9 100644 --- a/camel/providers/local/camel-mbox-folder.c +++ b/camel/providers/local/camel-mbox-folder.c @@ -2,7 +2,7 @@ * * Authors: Michael Zucchi <notzed@ximian.com> * - * Copyright (C) 1999, 2000 Ximian Inc. + * Copyright (C) 1999, 2003 Ximian Inc. * * This program is free software; you can redistribute it and/or * modify it under the terms of version 2 of the GNU General Public @@ -34,7 +34,6 @@ #include "camel-mbox-folder.h" #include "camel-mbox-store.h" -#include "string-utils.h" #include "camel-stream-fs.h" #include "camel-mbox-summary.h" #include "camel-data-wrapper.h" diff --git a/camel/providers/local/camel-mbox-summary.c b/camel/providers/local/camel-mbox-summary.c index 29eff1c83e..88d2a3e9a7 100644 --- a/camel/providers/local/camel-mbox-summary.c +++ b/camel/providers/local/camel-mbox-summary.c @@ -670,6 +670,8 @@ mbox_summary_sync_quick(CamelMboxSummary *mbs, gboolean expunge, CamelFolderChan xevtmp = header_unfold(xevnew); /* the raw header contains a leading ' ', so (dis)count that too */ if (strlen(xev)-1 != strlen(xevtmp)) { + printf ("strlen(xev)-1 = %d; strlen(xevtmp) = %d\n", strlen(xev)-1, strlen(xevtmp)); + printf ("xev='%s'; xevtmp='%s'\n", xev, xevtmp); g_free(xevnew); g_free(xevtmp); g_warning("Hmm, the xev headers shouldn't have changed size, but they did"); diff --git a/camel/providers/local/camel-mh-folder.c b/camel/providers/local/camel-mh-folder.c index 02d3370428..25dbacc49a 100644 --- a/camel/providers/local/camel-mh-folder.c +++ b/camel/providers/local/camel-mh-folder.c @@ -2,7 +2,7 @@ * * Authors: Michael Zucchi <notzed@ximian.com> * - * Copyright (C) 1999, 2000 Ximian Inc. + * Copyright (C) 1999, 2003 Ximian Inc. * * This program is free software; you can redistribute it and/or * modify it under the terms of version 2 of the GNU General Public @@ -34,7 +34,6 @@ #include "camel-mh-folder.h" #include "camel-mh-store.h" -#include "string-utils.h" #include "camel-stream-fs.h" #include "camel-mh-summary.h" #include "camel-data-wrapper.h" diff --git a/camel/providers/local/camel-spool-folder.c b/camel/providers/local/camel-spool-folder.c index d667310090..4c4a49fbf9 100644 --- a/camel/providers/local/camel-spool-folder.c +++ b/camel/providers/local/camel-spool-folder.c @@ -2,7 +2,7 @@ * * Authors: Michael Zucchi <notzed@ximian.com> * - * Copyright (C) 2001 Ximian Inc (www.ximian.com/) + * Copyright (C) 2001-2003 Ximian, Inc. (www.ximian.com) * * This program is free software; you can redistribute it and/or * modify it under the terms of version 2 of the GNU General Public @@ -34,7 +34,6 @@ #include "camel-spool-folder.h" #include "camel-spool-store.h" -#include "string-utils.h" #include "camel-stream-fs.h" #include "camel-spool-summary.h" #include "camel-data-wrapper.h" diff --git a/camel/providers/smtp/camel-smtp-transport.c b/camel/providers/smtp/camel-smtp-transport.c index c5947dc0ad..705fa2f5d8 100644 --- a/camel/providers/smtp/camel-smtp-transport.c +++ b/camel/providers/smtp/camel-smtp-transport.c @@ -55,7 +55,6 @@ #include "camel-session.h" #include "camel-exception.h" #include "camel-sasl.h" -#include "string-utils.h" extern int camel_verbose_debug; |