aboutsummaryrefslogtreecommitdiff
path: root/src/Mapper.cxx
diff options
context:
space:
mode:
authorDenis Krjuchkov <denis@crazydev.net>2013-01-24 02:26:38 +0600
committerDenis Krjuchkov <denis@crazydev.net>2013-01-28 00:13:45 +0600
commit3c7cf94643bc45237d1e61c4e6015d498e4400b0 (patch)
treebe93d9088f7b8199b0d07cce56017e6726a47f76 /src/Mapper.cxx
parent3bd35d188320f20a98a1004c001b132fc0975437 (diff)
Path: convert fs_charset_to_utf8() to static method Path::ToUTF8()
Diffstat (limited to 'src/Mapper.cxx')
-rw-r--r--src/Mapper.cxx6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/Mapper.cxx b/src/Mapper.cxx
index 1cb967eb..fa5af2db 100644
--- a/src/Mapper.cxx
+++ b/src/Mapper.cxx
@@ -246,7 +246,11 @@ map_fs_to_utf8(const char *path_fs)
while (path_fs[0] == G_DIR_SEPARATOR)
++path_fs;
- return fs_charset_to_utf8(path_fs);
+ const std::string path_utf8 = Path::ToUTF8(path_fs);
+ if (path_utf8.empty())
+ return nullptr;
+
+ return g_strdup(path_utf8.c_str());
}
const Path &