aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
Diffstat (limited to 'mail')
-rw-r--r--mail/ChangeLog6
-rw-r--r--mail/mail-format.c19
2 files changed, 16 insertions, 9 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 5d003485f3..d3b1725439 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,9 @@
+2000-06-01 Dan Winship <danw@helixcode.com>
+
+ * mail-format.c (write_headers): Oops. This needs to take a
+ message argument because we might be writing headers for an
+ embedded message/rfc822 subpart rather than the root document.
+
2000-06-01 Jeffrey Stedfast <fejj@helixcode.com>
* mail-config.c: Config dialogs are completed.
diff --git a/mail/mail-format.c b/mail/mail-format.c
index 0fc143488e..790d420f18 100644
--- a/mail/mail-format.c
+++ b/mail/mail-format.c
@@ -86,7 +86,8 @@ static void handle_via_bonobo (CamelMimePart *part,
struct mail_format_data *mfd);
/* writes the header info for a mime message into an html stream */
-static void write_headers (struct mail_format_data *mfd);
+static void write_headers (CamelMimeMessage *message,
+ struct mail_format_data *mfd);
/* dispatch html printing via mimetype */
static void call_handler_function (CamelMimePart *part,
@@ -123,7 +124,7 @@ mail_format_mime_message (CamelMimeMessage *mime_message,
mfd.urls, free_urls);
}
- write_headers (&mfd);
+ write_headers (mime_message, &mfd);
call_handler_function (CAMEL_MIME_PART (mime_message), &mfd);
}
@@ -385,7 +386,7 @@ write_recipients_to_stream (const gchar *recipient_type,
static void
-write_headers (struct mail_format_data *mfd)
+write_headers (CamelMimeMessage *message, struct mail_format_data *mfd)
{
const CamelInternetAddress *recipients;
@@ -395,24 +396,24 @@ write_headers (struct mail_format_data *mfd)
"<tr><td><table>\n");
write_field_to_stream ("From:",
- camel_mime_message_get_from (mfd->root),
+ camel_mime_message_get_from (message),
TRUE, mfd->html, mfd->stream);
- if (camel_mime_message_get_reply_to (mfd->root)) {
+ if (camel_mime_message_get_reply_to (message)) {
write_field_to_stream ("Reply-To:",
- camel_mime_message_get_reply_to (mfd->root),
+ camel_mime_message_get_reply_to (message),
FALSE, mfd->html, mfd->stream);
}
write_recipients_to_stream ("To:",
- camel_mime_message_get_recipients (mfd->root, CAMEL_RECIPIENT_TYPE_TO),
+ camel_mime_message_get_recipients (message, CAMEL_RECIPIENT_TYPE_TO),
FALSE, TRUE, mfd->html, mfd->stream);
- recipients = camel_mime_message_get_recipients (mfd->root, CAMEL_RECIPIENT_TYPE_CC);
+ recipients = camel_mime_message_get_recipients (message, CAMEL_RECIPIENT_TYPE_CC);
write_recipients_to_stream ("Cc:", recipients, TRUE, TRUE,
mfd->html, mfd->stream);
write_field_to_stream ("Subject:",
- camel_mime_message_get_subject (mfd->root),
+ camel_mime_message_get_subject (message),
TRUE, mfd->html, mfd->stream);
mail_html_write (mfd->html, mfd->stream, "</table></td></tr></table></center>");