aboutsummaryrefslogtreecommitdiffstats
path: root/camel
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2002-02-26 05:26:24 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2002-02-26 05:26:24 +0800
commit822bc5f1d92f2f0c481d84c2d40f6f1cf02a5e50 (patch)
tree84b7a6795d7cb46f7e91da41b6931d7a4db61824 /camel
parent7330d192f06105417dfaecacf1656033e19f63b8 (diff)
downloadgsoc2013-evolution-822bc5f1d92f2f0c481d84c2d40f6f1cf02a5e50.tar.gz
gsoc2013-evolution-822bc5f1d92f2f0c481d84c2d40f6f1cf02a5e50.tar.zst
gsoc2013-evolution-822bc5f1d92f2f0c481d84c2d40f6f1cf02a5e50.zip
Allow all multiparts that contain message/rfc822 attachments.
2002-02-25 Jeffrey Stedfast <fejj@ximian.com> * camel-digest-folder.c (camel_digest_folder_new): Allow all multiparts that contain message/rfc822 attachments. (digest_get_uids): Only assign uids to message parts. svn path=/trunk/; revision=15836
Diffstat (limited to 'camel')
-rw-r--r--camel/ChangeLog6
-rw-r--r--camel/camel-digest-folder.c21
2 files changed, 21 insertions, 6 deletions
diff --git a/camel/ChangeLog b/camel/ChangeLog
index 3e225e7ce3..f996021409 100644
--- a/camel/ChangeLog
+++ b/camel/ChangeLog
@@ -1,3 +1,9 @@
+2002-02-25 Jeffrey Stedfast <fejj@ximian.com>
+
+ * camel-digest-folder.c (camel_digest_folder_new): Allow all
+ multiparts that contain message/rfc822 attachments.
+ (digest_get_uids): Only assign uids to message parts.
+
2002-02-22 Jeffrey Stedfast <fejj@ximian.com>
* camel-mime-part.c (camel_mime_part_set_filename): Set the 'name'
diff --git a/camel/camel-digest-folder.c b/camel/camel-digest-folder.c
index f6cf3e8a93..cdc278c9fa 100644
--- a/camel/camel-digest-folder.c
+++ b/camel/camel-digest-folder.c
@@ -157,17 +157,21 @@ camel_digest_folder_new (CamelMimeMessage *message)
if (!wrapper || !CAMEL_IS_MULTIPART (wrapper))
return NULL;
- if (!header_content_type_is (CAMEL_MIME_PART (message)->content_type, "multipart", "digest")) {
+ if (!header_content_type_is (CAMEL_MIME_PART (message)->content_type, "multipart", "*")) {
+ gboolean is_digest = FALSE;
int i, parts;
/* Make sure we have a multipart of message/rfc822 attachments... */
parts = camel_multipart_get_number (CAMEL_MULTIPART (wrapper));
- for (i = 0; i < parts; i++) {
+ for (i = 0; i < parts && !is_digest; i++) {
CamelMimePart *part = camel_multipart_get_part (CAMEL_MULTIPART (wrapper), i);
- if (!header_content_type_is (part->content_type, "message", "rfc822"))
- return NULL;
+ if (header_content_type_is (part->content_type, "message", "rfc822"))
+ is_digest = TRUE;
}
+
+ if (!is_digest)
+ return NULL;
}
folder = CAMEL_FOLDER (camel_object_new (camel_digest_folder_get_type ()));
@@ -224,12 +228,16 @@ digest_get_uids (CamelFolder *folder)
CamelMimePart *part;
char *uid;
- uid = g_strdup_printf ("%d", i + 1);
-
part = camel_multipart_get_part (CAMEL_MULTIPART (wrapper), i);
+
+ if (!header_content_type_is (part->content_type, "message", "rfc822"))
+ continue;
+
message = CAMEL_MIME_MESSAGE (part);
info = camel_message_info_new_from_header (CAMEL_MIME_PART (message)->headers);
+
+ uid = g_strdup_printf ("%d", i + 1);
camel_message_info_set_uid (info, uid);
g_ptr_array_add (uids, uid);
@@ -294,6 +302,7 @@ digest_get_message (CamelFolder *folder, const char *uid, CamelException *ex)
int id;
id = atoi (uid) - 1;
+ g_assert (id > 0);
wrapper = camel_medium_get_content_object (CAMEL_MEDIUM (digest->priv->message));
part = camel_multipart_get_part (CAMEL_MULTIPART (wrapper), id);
commitgraph'>* Use default book, not local one.Dan Winship2002-08-133-3/+3 * Add include lines to get ebook headers relative to <ebook/foo.h>, notPeter Williams2002-07-111-0/+2 * Don't link with libibex.Jeffrey Stedfast2002-04-271-1/+0 * Change the OAFIID for the GtkHTML editor to have :1.1 at the end.Peter Williams2002-03-251-1/+1 * more fixes for libversit.la -> libversit.aDan Winship2002-03-201-1/+1 * ignore evolution-addressbook-abuseJeffrey Stedfast2002-01-301-0/+1 * Final cleanup for the CFLAGS and LIBS in the Makefiles.Ettore Perazzoli2002-01-281-20/+16 * cvs2vcard script by Michael MacDonald.Ettore Perazzoli2001-12-202-2/+245 * Chop the output from `uname -s'. Thanks to Michael Gerdts for suggestingEttore Perazzoli2001-11-101-0/+1 * Now more abusive.Jon Trowbridge2001-10-271-8/+22 * More abuse.Jon Trowbridge2001-10-271-3/+8 * Wombat: Be afraid. Be VERY afraid.Jon Trowbridge2001-10-272-0/+125 * and add a way to get some more spew about the commands we're executing.Chris Toshok2001-10-241-0/+11 * use eq instead of ==.Chris Toshok2001-10-241-5/+6 * Merge the two EXTRA_DIST declarations together so they both happen.Dan Winship2001-10-191-4/+2 * use a new fangled perl script that queries oaf for interfaces we want toChris Toshok2001-10-191-67/+128 * Bumped the required version of gal to 0.15.99.1 for use inChristopher James Lahey2001-10-195-2/+229 * kill evolution-ldif-importer.Chris Toshok2001-10-131-0/+2 * Ben said to do it.Christopher James Lahey2001-08-091-0/+1 * Added bonobo-moniker-xmldb, gnome-gtkhtml-editor andEttore Perazzoli2001-08-051-1/+26 * Added evolution-alarm-notify.Federico Mena Quintero2001-07-011-1/+2 * s/evolution-vcard-import/evolution-vcard-importerKjartan Maraas2001-05-231-1/+1 * Add in evolution-vcard-importer as part of the list of processes toDuncan Mak2001-05-211-0/+2 * add the importers.Chris Toshok2001-05-151-0/+6 * Kill the RDF Summary as well.Iain Holmes2001-05-101-0/+2 * add some more 16 character versions for freebsd.Chris Toshok2001-04-091-0/+2 * Fix this script to make it work with Solaris. Patch from Louise Miller.Jason Leach2001-02-021-19/+27 * new script to move tasks from the Calendar folder to the new Tasks folder,Damon Chaplin2001-01-142-1/+136 * Kill executive summary components72000-10-271-0/+3 * Update verify-evolution-install.sh a little teeny bit for 0.5 (no functionali...Peter Williams2000-10-161-2/+2 * Add verify-evolution-install.sh to EXTRA_DISTDan Winship2000-10-061-1/+1 * This is the baddest-ass script in the history of foreverPeter Williams2000-08-101-16/+170 * Look for oafinfo files in oaf's prefix, not gnome-libs's. Allow binariesDan Winship2000-08-061-3/+17 * Use type instead of which.Peter Williams2000-08-041-1/+1 * Ah, screw the which.Peter Williams2000-08-011-2/+2 * Stupid which program prints junk....Peter Williams2000-08-011-6/+10 * Backslashes are unneccessary. Prepositions are.Peter Williams2000-08-011-29/+29 * Now tests for OAF clienty goodnessPeter Williams2000-08-011-2/+2 * Now tests for OAF clienty goodnessPeter Williams2000-08-011-32/+88 * Updates to verifierPeter Williams2000-08-011-20/+39