diff options
author | Jeffrey Stedfast <fejj@ximian.com> | 2002-10-02 05:21:03 +0800 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2002-10-02 05:21:03 +0800 |
commit | 8427b2c852ed5200e28aaee5f8a74c678d931b25 (patch) | |
tree | a91bbd393709c01b1cd770b044b759e846b1ee20 /composer | |
parent | c0edd5dede35f46b26984b4b14af1e0e592f4dd8 (diff) | |
download | gsoc2013-evolution-8427b2c852ed5200e28aaee5f8a74c678d931b25.tar.gz gsoc2013-evolution-8427b2c852ed5200e28aaee5f8a74c678d931b25.tar.zst gsoc2013-evolution-8427b2c852ed5200e28aaee5f8a74c678d931b25.zip |
When signing/encrypting a part, if a USER_CANCEL occurs, re-use the part
2002-10-01 Jeffrey Stedfast <fejj@ximian.com>
* e-msg-composer.c (build_message): When signing/encrypting a
part, if a USER_CANCEL occurs, re-use the part otherwise unref it
and replace it with the new part.
svn path=/trunk/; revision=18290
Diffstat (limited to 'composer')
-rw-r--r-- | composer/ChangeLog | 6 | ||||
-rw-r--r-- | composer/e-msg-composer.c | 6 |
2 files changed, 10 insertions, 2 deletions
diff --git a/composer/ChangeLog b/composer/ChangeLog index d4704eb554..3aebb93f91 100644 --- a/composer/ChangeLog +++ b/composer/ChangeLog @@ -1,3 +1,9 @@ +2002-10-01 Jeffrey Stedfast <fejj@ximian.com> + + * e-msg-composer.c (build_message): When signing/encrypting a + part, if a USER_CANCEL occurs, re-use the part otherwise unref it + and replace it with the new part. + 2002-09-30 Aaron Weber <aaron@ximian.com> * evolution-composer.c (evolution_composer_factory_init): adjust string on line 391 diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c index 1dfe6667fe..383f8e5475 100644 --- a/composer/e-msg-composer.c +++ b/composer/e-msg-composer.c @@ -526,7 +526,6 @@ 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); @@ -536,10 +535,12 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data) if (camel_exception_get_id (&ex) == CAMEL_EXCEPTION_USER_CANCEL) { camel_exception_clear (&ex); } else { + camel_object_unref (part); camel_object_unref (mps); goto exception; } } else { + camel_object_unref (part); part = camel_mime_part_new (); camel_multipart_set_boundary (CAMEL_MULTIPART (mps), NULL); camel_medium_set_content_object (CAMEL_MEDIUM (part), (CamelDataWrapper *) mps); @@ -602,7 +603,6 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data) camel_multipart_encrypted_encrypt (mpe, part, cipher, userid, recipients, &ex); camel_object_unref (cipher); - camel_object_unref (part); if (from) camel_object_unref (from); @@ -617,9 +617,11 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data) camel_exception_clear (&ex); } else { camel_object_unref (mpe); + camel_object_unref (part); goto exception; } } else { + camel_object_unref (part); part = camel_mime_part_new (); camel_multipart_set_boundary (CAMEL_MULTIPART (mpe), NULL); camel_medium_set_content_object (CAMEL_MEDIUM (part), (CamelDataWrapper *) mpe); |