aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--composer/ChangeLog7
-rw-r--r--composer/e-msg-composer-attachment-bar.c9
-rw-r--r--composer/e-msg-composer.c17
3 files changed, 18 insertions, 15 deletions
diff --git a/composer/ChangeLog b/composer/ChangeLog
index 40d0335216..79ddbec540 100644
--- a/composer/ChangeLog
+++ b/composer/ChangeLog
@@ -1,3 +1,10 @@
+2003-07-23 Jeffrey Stedfast <fejj@ximian.com>
+
+ * e-msg-composer-attachment-bar.c (attach_to_multipart): Revert my
+ previous changes here too.
+
+ * e-msg-composer.c (build_message): Revert my previous changes.
+
2003-07-23 Dan Winship <danw@ximian.com>
* bad-icon.xpm: Remove this. It was only used by e-icon-list,
diff --git a/composer/e-msg-composer-attachment-bar.c b/composer/e-msg-composer-attachment-bar.c
index 05a1b549f3..b1e714ca7e 100644
--- a/composer/e-msg-composer-attachment-bar.c
+++ b/composer/e-msg-composer-attachment-bar.c
@@ -751,7 +751,14 @@ attach_to_multipart (CamelMultipart *multipart,
const char *charset;
char *type;
- charset = header_content_type_param (content_type, "charset");
+ /* assume that if a charset is set, that the content is in UTF-8
+ * or else already has rawtext set to TRUE */
+ if (!(charset = header_content_type_param (content_type, "charset"))) {
+ /* Let camel know that this text part was read in raw and thus is not in
+ * UTF-8 format so that when it writes this part out, it doesn't try to
+ * convert it from UTF-8 into the @default_charset charset. */
+ content->rawtext = TRUE;
+ }
stream = camel_stream_null_new ();
filter_stream = camel_stream_filter_new_with_stream (stream);
diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c
index 3e128129e7..31cddb46b1 100644
--- a/composer/e-msg-composer.c
+++ b/composer/e-msg-composer.c
@@ -404,22 +404,10 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
stream = camel_stream_mem_new_with_byte_array (data);
- /* convert the stream to the appropriate charset */
- if (charset && strcasecmp (charset, "UTF-8") != 0) {
- CamelStreamFilter *filter_stream;
- CamelMimeFilterCharset *filter;
-
- filter_stream = camel_stream_filter_new_with_stream (stream);
- camel_object_unref (stream);
-
- stream = (CamelStream *) filter_stream;
- filter = camel_mime_filter_charset_new_convert ("UTF-8", charset);
- camel_stream_filter_add (filter_stream, (CamelMimeFilter *) filter);
- camel_object_unref (filter);
- }
-
/* construct the content object */
plain = camel_data_wrapper_new ();
+ plain->rawtext = FALSE;
+
camel_data_wrapper_construct_from_stream (plain, stream);
camel_object_unref (stream);
@@ -448,6 +436,7 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
}
html = camel_data_wrapper_new ();
+ html->rawtext = FALSE;
stream = camel_stream_mem_new_with_byte_array (data);
camel_data_wrapper_construct_from_stream (html, stream);