1
0
mirror of https://github.com/d47081/qBittorrent.git synced 2025-01-09 14:27:56 +00:00

Unicode fix

This commit is contained in:
Christophe Dumez 2010-06-19 12:25:14 +00:00
parent c36fed3081
commit 061f1000cf

View File

@ -186,7 +186,7 @@ QString misc::truncateRootFolder(boost::intrusive_ptr<torrent_info> t) {
QStringList path_parts = path.split("/", QString::SkipEmptyParts); QStringList path_parts = path.split("/", QString::SkipEmptyParts);
if(path_parts.size() > 1) { if(path_parts.size() > 1) {
root_folder = path_parts.takeFirst(); root_folder = path_parts.takeFirst();
t->rename_file(i, std::string(path_parts.join("/").toUtf8())); t->rename_file(i, path_parts.join("/").toUtf8().data());
} }
++i; ++i;
} }
@ -202,7 +202,7 @@ QString misc::truncateRootFolder(libtorrent::torrent_handle h) {
QStringList path_parts = path.split("/", QString::SkipEmptyParts); QStringList path_parts = path.split("/", QString::SkipEmptyParts);
if(path_parts.size() > 1) { if(path_parts.size() > 1) {
root_folder = path_parts.takeFirst(); root_folder = path_parts.takeFirst();
h.rename_file(i, std::string(path_parts.join("/").toUtf8())); h.rename_file(i, path_parts.join("/").toUtf8().data());
} }
++i; ++i;
} }