From c953d6409dffd476370ba639118cba97bcda2f35 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Tue, 20 Oct 2009 21:01:55 +0200 Subject: mapper, update, ...: use g_build_filename(), G_DIR_SEPARATOR, ... Try to be as portable as possible, use GLib path name functions and macros. --- src/mapper.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/mapper.c') diff --git a/src/mapper.c b/src/mapper.c index 71127f51..a48e12a3 100644 --- a/src/mapper.c +++ b/src/mapper.c @@ -169,10 +169,10 @@ map_fs_to_utf8(const char *path_fs) { if (music_dir != NULL && strncmp(path_fs, music_dir, music_dir_length) == 0 && - path_fs[music_dir_length] == '/') + G_IS_DIR_SEPARATOR(path_fs[music_dir_length])) /* remove musicDir prefix */ path_fs += music_dir_length + 1; - else if (path_fs[0] == '/') + else if (G_IS_DIR_SEPARATOR(path_fs[0])) /* not within musicDir */ return NULL; -- cgit v1.2.3