aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--composer/ChangeLog6
-rw-r--r--composer/e-msg-composer.c5
2 files changed, 10 insertions, 1 deletions
diff --git a/composer/ChangeLog b/composer/ChangeLog
index de84b28383..afb4e44054 100644
--- a/composer/ChangeLog
+++ b/composer/ChangeLog
@@ -1,3 +1,9 @@
+2002-09-27 Jeffrey Stedfast <fejj@ximian.com>
+
+ * e-msg-composer.c (build_message): Don't reuse the part that
+ we've signed and/or encrypted, create a new part container
+ instead. Fixes bug #31379.
+
2002-09-25 Dan Winship <danw@ximian.com>
* e-msg-composer-hdrs.c (create_headers): Use "mail/*" for the
diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c
index 24dba9d583..2da8679807 100644
--- a/composer/e-msg-composer.c
+++ b/composer/e-msg-composer.c
@@ -526,6 +526,7 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
mps = camel_multipart_signed_new ();
camel_multipart_signed_sign (mps, cipher, part, userid, CAMEL_CIPHER_HASH_SHA1, &ex);
camel_object_unref (cipher);
+ camel_object_unref (part);
if (from)
camel_object_unref (from);
@@ -539,6 +540,7 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
goto exception;
}
} else {
+ part = camel_mime_part_new ();
camel_multipart_set_boundary (CAMEL_MULTIPART (mps), NULL);
camel_medium_set_content_object (CAMEL_MEDIUM (part), (CamelDataWrapper *) mps);
}
@@ -599,8 +601,8 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
cipher = mail_crypto_get_pgp_cipher_context (hdrs->account);
camel_multipart_encrypted_encrypt (mpe, part, cipher, userid, recipients, &ex);
-
camel_object_unref (cipher);
+ camel_object_unref (part);
if (from)
camel_object_unref (from);
@@ -618,6 +620,7 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
goto exception;
}
} else {
+ part = camel_mime_part_new ();
camel_multipart_set_boundary (CAMEL_MULTIPART (mpe), NULL);
camel_medium_set_content_object (CAMEL_MEDIUM (part), (CamelDataWrapper *) mpe);
}