[grilo-plugins] bookmarks: Don't use g_strconcat() to build paths



commit 6669ba611ae89a690699e76902826a6657989ffc
Author: Bastien Nocera <hadess hadess net>
Date:   Tue Mar 25 09:39:41 2014 +0100

    bookmarks: Don't use g_strconcat() to build paths
    
    Use g_build_filename() instead.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=673912

 src/bookmarks/grl-bookmarks.c |    6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)
---
diff --git a/src/bookmarks/grl-bookmarks.c b/src/bookmarks/grl-bookmarks.c
index 1a30356..c550a9a 100644
--- a/src/bookmarks/grl-bookmarks.c
+++ b/src/bookmarks/grl-bookmarks.c
@@ -224,16 +224,14 @@ grl_bookmarks_source_init (GrlBookmarksSource *source)
 
   source->priv = GRL_BOOKMARKS_GET_PRIVATE (source);
 
-  path = g_strconcat (g_get_user_data_dir (),
-                      G_DIR_SEPARATOR_S, "grilo-plugins",
-                      NULL);
+  path = g_build_filename (g_get_user_data_dir (), "grilo-plugins", NULL);
 
   if (!g_file_test (path, G_FILE_TEST_IS_DIR)) {
     g_mkdir_with_parents (path, 0775);
   }
 
   GRL_DEBUG ("Opening database connection...");
-  db_path = g_strconcat (path, G_DIR_SEPARATOR_S, GRL_SQL_DB, NULL);
+  db_path = g_build_filename (path, GRL_SQL_DB, NULL);
   g_free (path);
 
   source->priv->adapter = gom_adapter_new ();


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