[totem] save-file: Fix creation of cache directory



commit 0001090dc34e9623ae86f7629f0318c5a5017352
Author: Bastien Nocera <hadess hadess net>
Date:   Thu Apr 24 18:19:22 2014 +0200

    save-file: Fix creation of cache directory
    
    To hard-link a file to our cache directory, we'd better create it as
    well, otherwise it's just not going to work.
    
    See https://bugzilla.gnome.org/show_bug.cgi?id=727576

 src/plugins/save-file/totem-save-file.c |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/src/plugins/save-file/totem-save-file.c b/src/plugins/save-file/totem-save-file.c
index 52c8c95..6fb6f9a 100644
--- a/src/plugins/save-file/totem-save-file.c
+++ b/src/plugins/save-file/totem-save-file.c
@@ -106,7 +106,11 @@ copy_uris_with_nautilus (const char *source,
 static char *
 get_cache_path (void)
 {
-       return g_build_filename (g_get_user_cache_dir (), "totem", "media", NULL);
+       char *path;
+
+       path = g_build_filename (g_get_user_cache_dir (), "totem", "media", NULL);
+       g_mkdir_with_parents (path, 0755);
+       return path;
 }
 
 static void


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]