aboutsummaryrefslogtreecommitdiffstats
path: root/camel/camel-mime-part.c
diff options
context:
space:
mode:
authorDan Winship <danw@src.gnome.org>2000-04-27 05:50:34 +0800
committerDan Winship <danw@src.gnome.org>2000-04-27 05:50:34 +0800
commit82071abd45b2dbc7874c3556fbc03a503cf29bd3 (patch)
treeda18c230a78356018e30389a6207b52e1badca72 /camel/camel-mime-part.c
parentd24747d1b54305bbad38b0845e3d05a5401ed781 (diff)
downloadgsoc2013-evolution-82071abd45b2dbc7874c3556fbc03a503cf29bd3.tar
gsoc2013-evolution-82071abd45b2dbc7874c3556fbc03a503cf29bd3.tar.gz
gsoc2013-evolution-82071abd45b2dbc7874c3556fbc03a503cf29bd3.tar.bz2
gsoc2013-evolution-82071abd45b2dbc7874c3556fbc03a503cf29bd3.tar.lz
gsoc2013-evolution-82071abd45b2dbc7874c3556fbc03a503cf29bd3.tar.xz
gsoc2013-evolution-82071abd45b2dbc7874c3556fbc03a503cf29bd3.tar.zst
gsoc2013-evolution-82071abd45b2dbc7874c3556fbc03a503cf29bd3.zip
Only write a newline between the headers and the content object if the
* camel-mime-part.c (write_to_stream): Only write a newline between the headers and the content object if the content object is not a CamelMedium. (If the content is a medium, it may have its own headers, which then need to go before the blank line.) svn path=/trunk/; revision=2647
Diffstat (limited to 'camel/camel-mime-part.c')
-rw-r--r--camel/camel-mime-part.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/camel/camel-mime-part.c b/camel/camel-mime-part.c
index 6e2276df90..30c08a485f 100644
--- a/camel/camel-mime-part.c
+++ b/camel/camel-mime-part.c
@@ -504,11 +504,14 @@ write_to_stream (CamelDataWrapper *data_wrapper, CamelStream *stream)
}
}
- if ( (count = camel_stream_write_string(stream,"\n")) == -1)
- return -1;
- total += count;
-
content = camel_medium_get_content_object (medium);
+
+ if (!CAMEL_IS_MEDIUM (content)) {
+ if ( (count = camel_stream_write_string(stream,"\n")) == -1)
+ return -1;
+ total += count;
+ }
+
if (content) {
if ( (count = camel_data_wrapper_write_to_stream(content, stream)) == -1 )
return -1;