QString FileSystem::fileSystemForPath(const QString & path)
{
// See also QStorageInfo (Qt >=5.4) and GetVolumeInformationByHandleW (>= Vista)
- QString drive = path.left(3);
- if (! drive.endsWith(":\\"))
+ QString drive = path.left(2);
+ if (! drive.endsWith(":"))
return QString();
+ drive.append('\\');
const size_t fileSystemBufferSize = 4096;
TCHAR fileSystemBuffer[fileSystemBufferSize];
// See #2693: Some exFAT file systems seem unable to cope with the
// WAL journaling mode. They work fine with DELETE.
QString fileSystem = FileSystem::fileSystemForPath(dbPath);
+ qDebug() << "Detected filesystem" << fileSystem << "for" << dbPath;
if (fileSystem.contains("FAT")) {
- qDebug() << "Detected filesystem" << fileSystem << "- using DELETE journal mode";
+ qDebug() << "Filesystem contains FAT - using DELETE journal mode";
return "DELETE";
}
#else