summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoraavit <qt-info@nokia.com>2009-09-07 11:14:12 +0200
committeraavit <qt-info@nokia.com>2009-09-07 11:53:22 +0200
commitc4c9b4457f0f760c1bf46dd8a309ab76eb128c1d (patch)
treea671bb0c55780928136cfd62bd94533653e490e0
parent6b7330ee075a62138f005492a6448059106554af (diff)
Fix for qfileinfo autotest: LocalDiskFile set also for non-existing filev4.6.0-tp1
Change 53576b4d3c3e7325d01efba6c4da80299492f2db introduced the behaviour that QFSFileEngine sets LocalDiskFlag regardless of whether the file exists or not, but it just did it for Windows. This change makes fsengine for unix/mac behave likewise. Reviewed-by: trustme
-rw-r--r--src/corelib/io/qfsfileengine_unix.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/corelib/io/qfsfileengine_unix.cpp b/src/corelib/io/qfsfileengine_unix.cpp
index 022211c934..50b4af7809 100644
--- a/src/corelib/io/qfsfileengine_unix.cpp
+++ b/src/corelib/io/qfsfileengine_unix.cpp
@@ -731,6 +731,8 @@ QAbstractFileEngine::FileFlags QFSFileEngine::fileFlags(FileFlags type) const
}
QAbstractFileEngine::FileFlags ret = 0;
+ if (type & FlagsMask)
+ ret |= LocalDiskFlag;
bool exists = d->doStat();
if (!exists && !d->isSymlink())
return ret;
@@ -796,7 +798,6 @@ QAbstractFileEngine::FileFlags QFSFileEngine::fileFlags(FileFlags type) const
}
}
if (type & FlagsMask) {
- ret |= LocalDiskFlag;
if (exists)
ret |= ExistsFlag;
#if defined(Q_OS_SYMBIAN)