aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
authorDan Winship <danw@src.gnome.org>2001-04-13 01:47:06 +0800
committerDan Winship <danw@src.gnome.org>2001-04-13 01:47:06 +0800
commit09d998c3583e0b15e6efe4ce8af57aee5f5d98c4 (patch)
treecd4a8e60fac2cecf5f05024bc26c8cfb05bd2edf /mail
parent13acd44e987b0a08053f7970232ce3ca3fcf4fd0 (diff)
downloadgsoc2013-evolution-09d998c3583e0b15e6efe4ce8af57aee5f5d98c4.tar
gsoc2013-evolution-09d998c3583e0b15e6efe4ce8af57aee5f5d98c4.tar.gz
gsoc2013-evolution-09d998c3583e0b15e6efe4ce8af57aee5f5d98c4.tar.bz2
gsoc2013-evolution-09d998c3583e0b15e6efe4ce8af57aee5f5d98c4.tar.lz
gsoc2013-evolution-09d998c3583e0b15e6efe4ce8af57aee5f5d98c4.tar.xz
gsoc2013-evolution-09d998c3583e0b15e6efe4ce8af57aee5f5d98c4.tar.zst
gsoc2013-evolution-09d998c3583e0b15e6efe4ce8af57aee5f5d98c4.zip
Don't leak memory.
* mail-format.c (mail_part_is_inline): Don't leak memory. svn path=/trunk/; revision=9273
Diffstat (limited to 'mail')
-rw-r--r--mail/ChangeLog4
-rw-r--r--mail/mail-format.c7
2 files changed, 10 insertions, 1 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index f492ba39a8..9ffe778c10 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,7 @@
+2001-04-12 Dan Winship <danw@ximian.com>
+
+ * mail-format.c (mail_part_is_inline): Don't leak memory.
+
2001-04-12 Jeffrey Stedfast <fejj@ximian.com>
* mail-accounts.c (pgp_path_changed): Updated for changes to PGP
diff --git a/mail/mail-format.c b/mail/mail-format.c
index 63b90b913e..05144611bc 100644
--- a/mail/mail-format.c
+++ b/mail/mail-format.c
@@ -471,6 +471,8 @@ mail_part_is_inline (CamelMimePart *part)
{
const char *disposition;
CamelContentType *content_type;
+ char *type;
+ gboolean anon;
/* If it has an explicit disposition, return that. */
disposition = camel_mime_part_get_disposition (part);
@@ -487,7 +489,10 @@ mail_part_is_inline (CamelMimePart *part)
/* Otherwise, display it inline if it's "anonymous", and
* as an attachment otherwise.
*/
- return is_anonymous (part, header_content_type_simple (content_type));
+ type = header_content_type_simple (content_type);
+ anon = is_anonymous (part, type);
+ g_free (type);
+ return anon;
}
static void