ncmpcpp: convert input path to utf8 before calling 'add' command

this fixes the problem with adding files that contain non-ascii
characters while using different charset encoding than utf8.
This commit is contained in:
Andrzej Rybczak
2011-02-03 07:08:37 +01:00
parent e36f03f339
commit f3e1ba1c26

View File

@@ -1256,6 +1256,7 @@ int main(int argc, char *argv[])
LockStatusbar(); LockStatusbar();
Statusbar() << (myScreen == myPlaylistEditor ? "Add to playlist: " : "Add: "); Statusbar() << (myScreen == myPlaylistEditor ? "Add to playlist: " : "Add: ");
std::string path = wFooter->GetString(); std::string path = wFooter->GetString();
locale_to_utf(path);
UnlockStatusbar(); UnlockStatusbar();
if (!path.empty()) if (!path.empty())
{ {