From d433fb48d2667a93063fd8d92426c12bb31d3353 Mon Sep 17 00:00:00 2001 From: bertrand Date: Tue, 21 Mar 2000 15:28:36 +0000 Subject: display message size 2000-03-21 bertrand * message-list.c (ml_value_at): display message size 2000-03-21 bertrand * providers/mbox/camel-mbox-summary.c (camel_mbox_summary_append_internal_to_external): copy the size field * providers/mbox/camel-mbox-folder.c (_get_message_by_uid): initialize message_info to NULL * camel-folder-summary.h: added the size field. * providers/mbox/camel-mbox-summary.h: added the received_date field. svn path=/trunk/; revision=2133 --- camel/ChangeLog | 11 +++++++++++ camel/camel-folder-summary.h | 1 + camel/providers/mbox/camel-mbox-folder.c | 5 +---- camel/providers/mbox/camel-mbox-summary.c | 1 + camel/providers/mbox/camel-mbox-summary.h | 4 ++++ 5 files changed, 18 insertions(+), 4 deletions(-) (limited to 'camel') diff --git a/camel/ChangeLog b/camel/ChangeLog index 22249c483a..ff5d534bb0 100644 --- a/camel/ChangeLog +++ b/camel/ChangeLog @@ -1,5 +1,16 @@ 2000-03-21 bertrand + * providers/mbox/camel-mbox-summary.c + (camel_mbox_summary_append_internal_to_external): copy the size field + + * providers/mbox/camel-mbox-folder.c (_get_message_by_uid): initialize + message_info to NULL + + * camel-folder-summary.h: added the size field. + + * providers/mbox/camel-mbox-summary.h: + added the received_date field. + * providers/mbox/camel-mbox-summary.c: documented all functions. diff --git a/camel/camel-folder-summary.h b/camel/camel-folder-summary.h index 84facc41d5..88fe86bd9f 100644 --- a/camel/camel-folder-summary.h +++ b/camel/camel-folder-summary.h @@ -69,6 +69,7 @@ typedef struct { gchar *sent_date; gchar *received_date; + guint32 size; gchar *uid; GHashTable *extended_fields; diff --git a/camel/providers/mbox/camel-mbox-folder.c b/camel/providers/mbox/camel-mbox-folder.c index 34d3a5783a..fdba8279b3 100644 --- a/camel/providers/mbox/camel-mbox-folder.c +++ b/camel/providers/mbox/camel-mbox-folder.c @@ -179,7 +179,6 @@ _init (CamelFolder *folder, CamelStore *parent_store, CamelFolder *parent_folder, const gchar *name, gchar separator, CamelException *ex) { - CamelMboxFolder *mbox_folder = CAMEL_MBOX_FOLDER (folder); CAMEL_LOG_FULL_DEBUG ("Entering CamelMboxFolder::init_with_store\n"); @@ -463,7 +462,6 @@ _create (CamelFolder *folder, CamelException *ex) gint mkdir_error; gboolean folder_already_exists; int creat_fd; - mode_t old_umask; g_assert(folder != NULL); @@ -647,7 +645,6 @@ _delete_messages (CamelFolder *folder, CamelException *ex) const gchar *folder_file_path; gboolean folder_already_exists; int creat_fd; - mode_t old_umask; g_assert(folder!=NULL); @@ -1014,7 +1011,7 @@ _get_message_by_uid (CamelFolder *folder, const gchar *uid, CamelException *ex) CamelMboxFolder *mbox_folder = CAMEL_MBOX_FOLDER(folder); GArray *message_info_array; - CamelMboxSummaryInformation *message_info; + CamelMboxSummaryInformation *message_info = NULL; guint32 searched_uid; int i; gboolean uid_found; diff --git a/camel/providers/mbox/camel-mbox-summary.c b/camel/providers/mbox/camel-mbox-summary.c index 403355859a..9216f89e97 100644 --- a/camel/providers/mbox/camel-mbox-summary.c +++ b/camel/providers/mbox/camel-mbox-summary.c @@ -361,6 +361,7 @@ camel_mbox_summary_append_internal_to_external (CamelMboxSummary *internal, external_entry.uid = g_strdup_printf ("%u", internal_entry->uid); external_entry.sent_date = internal_entry->date ? strdup (internal_entry->date) : NULL; external_entry.sender = internal_entry->sender ? strdup (internal_entry->sender) : NULL; + external_entry.size = internal_entry->size; g_array_append_vals (external_array, &external_entry, 1); diff --git a/camel/providers/mbox/camel-mbox-summary.h b/camel/providers/mbox/camel-mbox-summary.h index af64ff7cf5..4ee4770a03 100644 --- a/camel/providers/mbox/camel-mbox-summary.h +++ b/camel/providers/mbox/camel-mbox-summary.h @@ -29,6 +29,8 @@ +/* This contains information about one message inside + * the mbox file. This is used in the intenal summary */ typedef struct { guint32 position; @@ -40,10 +42,12 @@ typedef struct { gchar *sender; gchar *to; gchar *date; + gchar *received_date; } CamelMboxSummaryInformation; +/* this contains informations about the whole mbox file */ typedef struct { guint nb_message; /* number of messages in the summary */ -- cgit