[evolution-data-server] Remove camel_folder_summary_decode_token().
- From: Matthew Barnes <mbarnes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-data-server] Remove camel_folder_summary_decode_token().
- Date: Sun, 13 Nov 2011 06:05:27 +0000 (UTC)
commit a2a5a3fc63b4ebd7293f20b107da7600b088c1ea
Author: Matthew Barnes <mbarnes redhat com>
Date: Sun Nov 13 00:36:46 2011 -0500
Remove camel_folder_summary_decode_token().
No longer needed.
camel/camel-folder-summary.c | 87 -------------------------------
camel/camel-folder-summary.h | 5 --
docs/reference/camel/camel-sections.txt | 1 -
3 files changed, 0 insertions(+), 93 deletions(-)
---
diff --git a/camel/camel-folder-summary.c b/camel/camel-folder-summary.c
index 808a001..c6d4f27 100644
--- a/camel/camel-folder-summary.c
+++ b/camel/camel-folder-summary.c
@@ -3227,93 +3227,6 @@ camel_folder_summary_remove_uid (CamelFolderSummary *summary,
return res;
}
-/* should be sorted, for binary search */
-/* This is a tokenisation mechanism for strings written to the
- * summary - to save space.
- * This list can have at most 31 words. */
-static const gchar * tokens[] = {
- "7bit",
- "8bit",
- "alternative",
- "application",
- "base64",
- "boundary",
- "charset",
- "filename",
- "html",
- "image",
- "iso-8859-1",
- "iso-8859-8",
- "message",
- "mixed",
- "multipart",
- "name",
- "octet-stream",
- "parallel",
- "plain",
- "postscript",
- "quoted-printable",
- "related",
- "rfc822",
- "text",
- "us-ascii", /* 25 words */
-};
-
-/**
- * camel_folder_summary_decode_token:
- * @in: input FILE pointer
- * @str: string pointer to hold the decoded result
- *
- * Decode a token value.
- *
- * Returns: %0 on success or %-1 on fail
- **/
-gint
-camel_folder_summary_decode_token (FILE *in,
- gchar **str)
-{
- gchar *ret;
- guint32 len;
-
- io(printf("Decode token ...\n"));
-
- if (camel_file_util_decode_uint32 (in, &len) == -1) {
- io(printf ("Could not decode token from file"));
- *str = NULL;
- return -1;
- }
-
- if (len < 32) {
- if (len <= 0) {
- ret = NULL;
- } else if (len<= G_N_ELEMENTS (tokens)) {
- ret = g_strdup (tokens[len - 1]);
- } else {
- io(printf ("Invalid token encountered: %d", len));
- *str = NULL;
- return -1;
- }
- } else if (len > 10240) {
- io(printf ("Got broken string header length: %d bytes", len));
- *str = NULL;
- return -1;
- } else {
- len -= 32;
- ret = g_malloc (len + 1);
- if (len > 0 && fread (ret, len, 1, in) != 1) {
- g_free (ret);
- *str = NULL;
- return -1;
- }
- ret[len]=0;
- }
-
- io(printf("Token = '%s'\n", ret));
-
- *str = ret;
- return 0;
-}
-
static struct _node *
my_list_append (struct _node **list,
struct _node *n)
diff --git a/camel/camel-folder-summary.h b/camel/camel-folder-summary.h
index 2578952..cb66520 100644
--- a/camel/camel-folder-summary.h
+++ b/camel/camel-folder-summary.h
@@ -437,11 +437,6 @@ void camel_folder_summary_lock (CamelFolderSummary *summary,
void camel_folder_summary_unlock (CamelFolderSummary *summary,
CamelFolderSummaryLock lock);
-/* basically like strings, but certain keywords can be compressed and de-cased */
-gint camel_folder_summary_decode_token
- (FILE *in,
- gchar **str);
-
/* message flag operations */
gboolean camel_flag_get (CamelFlag **list,
const gchar *name);
diff --git a/docs/reference/camel/camel-sections.txt b/docs/reference/camel/camel-sections.txt
index 6200cc3..bab85b1 100644
--- a/docs/reference/camel/camel-sections.txt
+++ b/docs/reference/camel/camel-sections.txt
@@ -625,7 +625,6 @@ camel_folder_summary_get_changed
camel_folder_summary_prepare_fetch_all
camel_folder_summary_lock
camel_folder_summary_unlock
-camel_folder_summary_decode_token
camel_flag_get
camel_flag_set
camel_flag_list_copy
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]