From ca5d6d6a338fbe5d8e6b24b85f681b9df07ce392 Mon Sep 17 00:00:00 2001 From: Milan Crha Date: Thu, 16 Aug 2007 10:51:06 +0000 Subject: 2007-08-16 mcrha Part of fix for bug #350539 svn path=/trunk/; revision=34017 --- mail/em-format.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'mail/em-format.c') diff --git a/mail/em-format.c b/mail/em-format.c index 40e2661706..7584f3301f 100644 --- a/mail/em-format.c +++ b/mail/em-format.c @@ -1243,6 +1243,10 @@ emf_multipart_alternative(EMFormat *emf, CamelStream *stream, CamelMimePart *par /* is it correct to use the passed in *part here? */ part = camel_multipart_get_part(mp, i); + + if (!part) + continue; + type = camel_mime_part_get_content_type (part); mime_type = camel_content_type_simple (type); @@ -1533,7 +1537,12 @@ emf_inlinepgp_signed(EMFormat *emf, CamelStream *stream, CamelMimePart *ipart, E CamelStream *ostream; CamelException *ex; char *type; - + + if (!ipart) { + em_format_format_error(emf, stream, _("Unknown error verifying signature")); + return; + } + ex = camel_exception_new(); cipher = camel_gpg_context_new(emf->session); /* Verify the signature of the message */ -- cgit v1.2.3