summaryrefslogtreecommitdiff
path: root/src/mapper.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-12-14 17:40:50 +0100
committerMax Kellermann <max@duempel.org>2009-12-14 17:40:50 +0100
commitc3085d7b6130f24c3a1675e902bffb23775d5c3e (patch)
tree9960c6e1dbbebd9b99f7cec3dab8e54f06ef8182 /src/mapper.c
parent179502fe93532a3686c08f07d9ef6effaaf4f25a (diff)
parent8f7bc70bf5e47da66e57e5606b978ba3ee975d89 (diff)
Merge branch 'v0.15.x'
Conflicts: src/decoder/ffmpeg_plugin.c
Diffstat (limited to 'src/mapper.c')
-rw-r--r--src/mapper.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/src/mapper.c b/src/mapper.c
index bc3647686..0c3348aa1 100644
--- a/src/mapper.c
+++ b/src/mapper.c
@@ -192,14 +192,19 @@ map_spl_path(void)
char *
map_spl_utf8_to_fs(const char *name)
{
- char *filename = g_strconcat(name, PLAYLIST_FILE_SUFFIX, NULL);
- char *path;
+ char *filename_utf8, *filename_fs, *path;
if (playlist_dir == NULL)
return NULL;
- path = g_build_filename(playlist_dir, filename, NULL);
- g_free(filename);
+ filename_utf8 = g_strconcat(name, PLAYLIST_FILE_SUFFIX, NULL);
+ filename_fs = utf8_to_fs_charset(filename_utf8);
+ g_free(filename_utf8);
+ if (filename_fs == NULL)
+ return NULL;
+
+ path = g_build_filename(playlist_dir, filename_fs, NULL);
+ g_free(filename_fs);
return path;
}