aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/audio-inline/audio-inline.c
diff options
context:
space:
mode:
authorMilan Crha <mcrha@src.gnome.org>2007-08-16 18:51:06 +0800
committerMilan Crha <mcrha@src.gnome.org>2007-08-16 18:51:06 +0800
commitca5d6d6a338fbe5d8e6b24b85f681b9df07ce392 (patch)
tree45fb3d086d27a695be5eff6ae9f7a8d47d23fd7b /plugins/audio-inline/audio-inline.c
parent6ee27498e11e532a971cbb10659d754a7c2a577d (diff)
downloadgsoc2013-evolution-ca5d6d6a338fbe5d8e6b24b85f681b9df07ce392.tar.gz
gsoc2013-evolution-ca5d6d6a338fbe5d8e6b24b85f681b9df07ce392.tar.zst
gsoc2013-evolution-ca5d6d6a338fbe5d8e6b24b85f681b9df07ce392.zip
2007-08-16 mcrha Part of fix for bug #350539
svn path=/trunk/; revision=34017
Diffstat (limited to 'plugins/audio-inline/audio-inline.c')
-rw-r--r--plugins/audio-inline/audio-inline.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/plugins/audio-inline/audio-inline.c b/plugins/audio-inline/audio-inline.c
index dd9621ce6b..615e06446c 100644
--- a/plugins/audio-inline/audio-inline.c
+++ b/plugins/audio-inline/audio-inline.c
@@ -214,14 +214,16 @@ org_gnome_audio_inline_play_clicked (GtkWidget *button, EMFormatHTMLPObject *pob
d(printf ("audio inline formatter: init gst thread\n"));
if (gst_init_check (&argc, (char ***) &argv)) {
- CamelContentType *type;
+ CamelContentType *type = NULL;
GstElement *filesrc;
/* create a disk reader */
filesrc = gst_element_factory_make ("filesrc", "disk_source");
g_object_set (G_OBJECT (filesrc), "location", po->filename, NULL);
- type = camel_mime_part_get_content_type (po->part);
+ if (po->part)
+ type = camel_mime_part_get_content_type (po->part);
+
if (type) {
if (!g_ascii_strcasecmp (type->type, "audio")) {
if (!g_ascii_strcasecmp (type->subtype, "mpeg") || !g_ascii_strcasecmp (type->subtype, "x-mpeg")