[Pkg-owncloud-commits] [owncloud-client] 122/171: Win: Fix filesystem detection for exFAT workaround #2701
Sandro Knauß
hefee-guest at moszumanska.debian.org
Wed Feb 17 09:36:58 UTC 2016
This is an automated email from the git hooks/post-receive script.
hefee-guest pushed a commit to annotated tag upstream/2.1.1+dfsg
in repository owncloud-client.
commit 17895f3a30bf44469e183af7860333a5918ef9f0
Author: Christian Kamm <mail at ckamm.de>
Date: Tue Jan 19 09:58:00 2016 +0100
Win: Fix filesystem detection for exFAT workaround #2701
---
src/libsync/filesystem.cpp | 5 +++--
src/libsync/syncjournaldb.cpp | 3 ++-
2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/src/libsync/filesystem.cpp b/src/libsync/filesystem.cpp
index 3cd2781..09fd168 100644
--- a/src/libsync/filesystem.cpp
+++ b/src/libsync/filesystem.cpp
@@ -476,9 +476,10 @@ bool FileSystem::fileExists(const QString& filename, const QFileInfo& fileInfo)
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];
diff --git a/src/libsync/syncjournaldb.cpp b/src/libsync/syncjournaldb.cpp
index 1fa8c54..d492efa 100644
--- a/src/libsync/syncjournaldb.cpp
+++ b/src/libsync/syncjournaldb.cpp
@@ -112,8 +112,9 @@ static QString defaultJournalMode(const QString & dbPath)
// 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
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud-client.git
More information about the Pkg-owncloud-commits
mailing list