aboutsummaryrefslogtreecommitdiffstats
path: root/composer
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@novell.com>2004-10-12 00:51:17 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2004-10-12 00:51:17 +0800
commit2432e22d47ec0c9bc190988a0708b4f13a0aa183 (patch)
tree79073299fee12406c72e353be9b8a49c686289b8 /composer
parentf20b83d0b8fd973a37d05e4c722669655a3f6aa5 (diff)
downloadgsoc2013-evolution-2432e22d47ec0c9bc190988a0708b4f13a0aa183.tar.gz
gsoc2013-evolution-2432e22d47ec0c9bc190988a0708b4f13a0aa183.tar.zst
gsoc2013-evolution-2432e22d47ec0c9bc190988a0708b4f13a0aa183.zip
g_strdup() the gpg/smime keys into the recipients list or else we end up
2004-10-08 Jeffrey Stedfast <fejj@novell.com> * e-msg-composer.c (build_message): g_strdup() the gpg/smime keys into the recipients list or else we end up free'ing them later when we shouldn't. Fixes bug #66703 svn path=/trunk/; revision=27537
Diffstat (limited to 'composer')
-rw-r--r--composer/ChangeLog6
-rw-r--r--composer/e-msg-composer.c4
2 files changed, 8 insertions, 2 deletions
diff --git a/composer/ChangeLog b/composer/ChangeLog
index 6b5f92db60..a09bbbb640 100644
--- a/composer/ChangeLog
+++ b/composer/ChangeLog
@@ -1,3 +1,9 @@
+2004-10-08 Jeffrey Stedfast <fejj@novell.com>
+
+ * e-msg-composer.c (build_message): g_strdup() the gpg/smime keys
+ into the recipients list or else we end up free'ing them later
+ when we shouldn't. Fixes bug #66703
+
2004-10-06 Not Zed <NotZed@Ximian.com>
* e-msg-composer.c (drag_data_received):
diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c
index a282a568f2..9d1dc1c347 100644
--- a/composer/e-msg-composer.c
+++ b/composer/e-msg-composer.c
@@ -676,7 +676,7 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
/* check to see if we should encrypt to self, NB gets removed immediately after use */
if (hdrs->account && hdrs->account->pgp_encrypt_to_self && pgp_userid)
- g_ptr_array_add (recipients, (char *)pgp_userid);
+ g_ptr_array_add (recipients, g_strdup (pgp_userid));
cipher = mail_crypto_get_pgp_cipher_context (hdrs->account);
camel_cipher_encrypt(cipher, pgp_userid, recipients, part, npart, &ex);
@@ -755,7 +755,7 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
if (composer->smime_encrypt) {
/* check to see if we should encrypt to self, NB removed after use */
if (hdrs->account->smime_encrypt_to_self)
- g_ptr_array_add(recipients, hdrs->account->smime_encrypt_key);
+ g_ptr_array_add(recipients, g_strdup (hdrs->account->smime_encrypt_key));
cipher = camel_smime_context_new(session);
camel_smime_context_set_encrypt_key((CamelSMIMEContext *)cipher, TRUE, hdrs->account->smime_encrypt_key);