Fix possible string encoding problem

This commit is contained in:
Christophe Dumez
2010-10-23 15:26:08 +00:00
parent 7c34f4e93c
commit e863772159

View File

@@ -2177,7 +2177,7 @@ void Bittorrent::addConsoleMessage(QString msg, QString) {
if(h.is_valid()) {
// Attempt to remove old folder if empty
const QString& old_save_path = TorrentPersistentData::getPreviousPath(h.hash());
const QString new_save_path = QString::fromLocal8Bit(p->path.c_str());
const QString new_save_path = misc::toQStringU(p->path);
qDebug("Torrent moved from %s to %s", qPrintable(old_save_path), qPrintable(new_save_path));
QDir old_save_dir(old_save_path);
if(old_save_dir != QDir(defaultSavePath) && old_save_dir != QDir(defaultTempPath)) {