forked from Ivasoft/DSView
add support for path with chinese characters
This commit is contained in:
@@ -106,8 +106,9 @@ std::list<boost::shared_ptr<device::DevInst> > DeviceManager::driver_scan(
|
||||
QDir dir(QCoreApplication::applicationDirPath());
|
||||
if (!dir.cd("res"))
|
||||
return driver_devices;
|
||||
std::string str = dir.absolutePath().toStdString() + "/";
|
||||
strcpy(config_path, str.c_str());
|
||||
QString str = dir.absolutePath() + "/";
|
||||
QString str_utf8 = QString::fromLocal8Bit(str.toLocal8Bit());
|
||||
strcpy(config_path, str_utf8.toUtf8().data());
|
||||
}
|
||||
|
||||
// Do the scan
|
||||
|
||||
Reference in New Issue
Block a user