summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBastien Nocera <hadess@hadess.net>2012-04-05 17:35:45 +0100
committerBastien Nocera <hadess@hadess.net>2012-04-05 18:01:32 +0100
commit85dfd9430f06283562bbac6a0be3b6de2a36cf6e (patch)
treee1fc02c4af9c05d631a272d3a44e73cf24b6f12a /src
parent42bf03207b0b05693c294ca771b3bef0cfbe8140 (diff)
downloadtotem-85dfd9430f06283562bbac6a0be3b6de2a36cf6e.tar.gz
thumbnailer: Fix thumbnailing an archive:/// DVD image
Diffstat (limited to 'src')
-rw-r--r--src/totem-video-thumbnailer.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/totem-video-thumbnailer.c b/src/totem-video-thumbnailer.c
index cf33774bc..66e075b74 100644
--- a/src/totem-video-thumbnailer.c
+++ b/src/totem-video-thumbnailer.c
@@ -88,22 +88,23 @@ static void save_pixbuf (GdkPixbuf *pixbuf, const char *path,
static char *
get_special_url (GFile *file)
{
- char *path, *uri, *mime_type;
+ char *path, *orig_uri, *uri, *mime_type;
TotemDiscMediaType type;
path = g_file_get_path (file);
mime_type = g_content_type_guess (path, NULL, 0, NULL);
+ g_free (path);
if (g_strcmp0 (mime_type, "application/x-cd-image") != 0) {
- g_free (path);
g_free (mime_type);
return NULL;
}
g_free (mime_type);
uri = NULL;
- type = totem_cd_detect_type_with_url (path, &uri, NULL);
- g_free (path);
+ orig_uri = g_file_get_uri (file);
+ type = totem_cd_detect_type_with_url (orig_uri, &uri, NULL);
+ g_free (orig_uri);
if (type == MEDIA_TYPE_DVD ||
type == MEDIA_TYPE_VCD)