# HG changeset patch # User zas_ # Date 1211367158 0 # Node ID 9973edfd86f6762c81022bee218468fc9149e1ed # Parent 7638e83fed2acefc2ea7b3770c6702f9c41f1d38 Use g_build_filename() and G_DIR_SEPARATOR_S. diff -r 7638e83fed2a -r 9973edfd86f6 src/view_dir_list.c --- a/src/view_dir_list.c Wed May 21 10:46:33 2008 +0000 +++ b/src/view_dir_list.c Wed May 21 10:52:38 2008 +0000 @@ -227,9 +227,9 @@ /* add . and .. */ - if (strcmp(vd->path, "/") != 0) + if (strcmp(vd->path, G_DIR_SEPARATOR_S) != 0) { - filepath = g_strconcat(vd->path, "/", "..", NULL); + filepath = g_build_filename(vd->path, "..", NULL); fd = file_data_new_simple(filepath); VDLIST_INFO(vd, list) = g_list_prepend(VDLIST_INFO(vd, list), fd); g_free(filepath); @@ -237,7 +237,7 @@ if (options->file_filter.show_dot_directory) { - filepath = g_strconcat(vd->path, "/", ".", NULL); + filepath = g_build_filename(vd->path, ".", NULL); fd = file_data_new_simple(filepath); VDLIST_INFO(vd, list) = g_list_prepend(VDLIST_INFO(vd, list), fd); g_free(filepath);