diff options
author | Max Kellermann <max@duempel.org> | 2013-01-17 00:56:57 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2013-01-18 15:34:01 +0100 |
commit | e5039c478aa93e3e107ee9031a3cf27a6c203fea (patch) | |
tree | 5d9fecc644b915fe02634911d65c29123e03c1b8 /src/ExcludeList.cxx | |
parent | 890151450663abd581cab56e853e8e713d822851 (diff) | |
download | mpd-e5039c478aa93e3e107ee9031a3cf27a6c203fea.tar.gz mpd-e5039c478aa93e3e107ee9031a3cf27a6c203fea.tar.xz mpd-e5039c478aa93e3e107ee9031a3cf27a6c203fea.zip |
Path: new class "Path" wraps filesystem path strings
Diffstat (limited to '')
-rw-r--r-- | src/ExcludeList.cxx | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/ExcludeList.cxx b/src/ExcludeList.cxx index 2c2dc952f..3f929b93c 100644 --- a/src/ExcludeList.cxx +++ b/src/ExcludeList.cxx @@ -32,14 +32,12 @@ #include <errno.h> bool -ExcludeList::LoadFile(const char *path_fs) +ExcludeList::LoadFile(const Path &path_fs) { - assert(path_fs != NULL); - - FILE *file = fopen(path_fs, "r"); + FILE *file = fopen(path_fs.c_str(), "r"); if (file == NULL) { if (errno != ENOENT) { - char *path_utf8 = fs_charset_to_utf8(path_fs); + char *path_utf8 = path_fs.ToUTF8(); g_debug("Failed to open %s: %s", path_utf8, g_strerror(errno)); g_free(path_utf8); |