aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2001-04-23 08:21:42 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2001-04-23 08:21:42 +0800
commitb0795401c735bea2aab3fb0da4f4a8824d8e210a (patch)
tree49ec42bc3cca4d70490d37fab7d09ad108d1ce52
parentc467d07a94176d5972c683df37ce186ab8440e35 (diff)
downloadgsoc2013-evolution-b0795401c735bea2aab3fb0da4f4a8824d8e210a.tar.gz
gsoc2013-evolution-b0795401c735bea2aab3fb0da4f4a8824d8e210a.tar.zst
gsoc2013-evolution-b0795401c735bea2aab3fb0da4f4a8824d8e210a.zip
Make sure we have a context before we try and use it.
2001-04-22 Jeffrey Stedfast <fejj@ximian.com> * mail-crypto.c (mail_crypto_pgp_mime_part_sign): Make sure we have a context before we try and use it. svn path=/trunk/; revision=9496
-rw-r--r--mail/ChangeLog5
-rw-r--r--mail/mail-crypto.c7
2 files changed, 10 insertions, 2 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 57ddff2d0b..a312b8ae00 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,8 @@
+2001-04-22 Jeffrey Stedfast <fejj@ximian.com>
+
+ * mail-crypto.c (mail_crypto_pgp_mime_part_sign): Make sure we
+ have a context before we try and use it.
+
2001-04-22 Gediminas Paulauskas <menesis@delfi.lt>
* folder-browser.c, mail-autofilter.c, mail-callbacks.c, mail-ops.c,
diff --git a/mail/mail-crypto.c b/mail/mail-crypto.c
index 7fb3aba88d..9572a5edbb 100644
--- a/mail/mail-crypto.c
+++ b/mail/mail-crypto.c
@@ -139,8 +139,11 @@ mail_crypto_pgp_mime_part_sign (CamelMimePart **mime_part, const char *userid, C
context = camel_pgp_context_new (session, mail_config_get_pgp_type (),
mail_config_get_pgp_path ());
- camel_pgp_mime_part_sign (context, mime_part, userid, hash, ex);
- camel_object_unref (CAMEL_OBJECT (context));
+
+ if (context) {
+ camel_pgp_mime_part_sign (context, mime_part, userid, hash, ex);
+ camel_object_unref (CAMEL_OBJECT (context));
+ }
}