aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2003-08-14 12:35:22 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2003-08-14 12:35:22 +0800
commit1f607a46c3b950f00be5190c0f803526764cb4d4 (patch)
tree3fd7dd27063de3f24a3d1ff65dacb56c86b15a1e
parenteceeca1b9f2176af9b27c811ab6d2e760859f929 (diff)
downloadgsoc2013-evolution-1f607a46c3b950f00be5190c0f803526764cb4d4.tar
gsoc2013-evolution-1f607a46c3b950f00be5190c0f803526764cb4d4.tar.gz
gsoc2013-evolution-1f607a46c3b950f00be5190c0f803526764cb4d4.tar.bz2
gsoc2013-evolution-1f607a46c3b950f00be5190c0f803526764cb4d4.tar.lz
gsoc2013-evolution-1f607a46c3b950f00be5190c0f803526764cb4d4.tar.xz
gsoc2013-evolution-1f607a46c3b950f00be5190c0f803526764cb4d4.tar.zst
gsoc2013-evolution-1f607a46c3b950f00be5190c0f803526764cb4d4.zip
Save errno when flushing/unreffing the filter stream.
2003-08-14 Jeffrey Stedfast <fejj@ximian.com> * camel-mime-part.c (write_to_stream): Save errno when flushing/unreffing the filter stream. svn path=/trunk/; revision=22227
-rw-r--r--camel/ChangeLog5
-rw-r--r--camel/camel-mime-part.c9
2 files changed, 11 insertions, 3 deletions
diff --git a/camel/ChangeLog b/camel/ChangeLog
index b1e3b95563..406d9428b2 100644
--- a/camel/ChangeLog
+++ b/camel/ChangeLog
@@ -1,3 +1,8 @@
+2003-08-14 Jeffrey Stedfast <fejj@ximian.com>
+
+ * camel-mime-part.c (write_to_stream): Save errno when
+ flushing/unreffing the filter stream.
+
2003-08-13 Jeffrey Stedfast <fejj@ximian.com>
* camel-mime-part.c (write_to_stream): If the content is
diff --git a/camel/camel-mime-part.c b/camel/camel-mime-part.c
index 5fdfac5ef8..81036c0571 100644
--- a/camel/camel-mime-part.c
+++ b/camel/camel-mime-part.c
@@ -629,12 +629,13 @@ write_to_stream (CamelDataWrapper *dw, CamelStream *stream)
CamelDataWrapper *content;
ssize_t total = 0;
ssize_t count;
-
+ int errnosav;
+
d(printf("mime_part::write_to_stream\n"));
-
+
/* FIXME: something needs to be done about this ... */
/* TODO: content-languages header? */
-
+
if (mp->headers) {
struct _header_raw *h = mp->headers;
char *val;
@@ -746,8 +747,10 @@ write_to_stream (CamelDataWrapper *dw, CamelStream *stream)
count = camel_data_wrapper_write_to_stream (content, stream);
if (filter_stream) {
+ errnosav = errno;
camel_stream_flush (stream);
camel_object_unref (filter_stream);
+ errno = errnosav;
}
if (count == -1)