[devhelp] book-manager: Don't pass separator to g_build_filename



commit 48dab0a389bb04539f5a10d535a9a79552812379
Author: Arnel A. Borja <kyoushuu yahoo com>
Date:   Sat May 18 19:03:16 2013 +0800

    book-manager: Don't pass separator to g_build_filename
    
    g_build_filename automatically adds G_DIR_SEPARATOR_S and its parameters should
    be the components of the path. Passing G_DIR_SEPARATOR_S to it will add another
    separator to the start of the path.
    
    Probably a confusion with g_build_path, which needs the separator as its first
    parameter.

 src/dh-book-manager.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
---
diff --git a/src/dh-book-manager.c b/src/dh-book-manager.c
index 06b0c49..6f694c1 100644
--- a/src/dh-book-manager.c
+++ b/src/dh-book-manager.c
@@ -528,8 +528,7 @@ book_manager_add_from_dir (DhBookManager *book_manager,
 
                 /* Build the path of the directory where the final
                  * devhelp book resides */
-                book_dir_path = g_build_filename (G_DIR_SEPARATOR_S,
-                                                  dir_path,
+                book_dir_path = g_build_filename (dir_path,
                                                   name,
                                                   NULL);
 


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