summaryrefslogtreecommitdiffstats
path: root/src/corelib/io
diff options
context:
space:
mode:
authorMurray Read <ext-murray.2.read@nokia.com>2012-02-06 15:33:30 (GMT)
committerQt by Nokia <qt-info@nokia.com>2012-02-08 00:52:00 (GMT)
commitf343fc7c0844fc33886f3e25d49e043062c06e7a (patch)
tree454ed6aeb7d28e662822b18eaf606e9517cb6622 /src/corelib/io
parentf41135a9f83d17b319ad050dfacc7a8e88598151 (diff)
downloadQt-f343fc7c0844fc33886f3e25d49e043062c06e7a.zip
Qt-f343fc7c0844fc33886f3e25d49e043062c06e7a.tar.gz
Qt-f343fc7c0844fc33886f3e25d49e043062c06e7a.tar.bz2
Changes in Symbian CleanupStack use to allow dodgy app start
Some important apps were found to invoke Qt code using the Symbian CleanupStack during static data initialization. This is not legal Qt code, but due to the importance of maintaining compatability with these apps, Qt has been modified to avoid the problem. In one case by removing unnessary use of CleanupStack. In the other by creating a temporary CleanupStack. Task-number: ou1cimx1#960665 Change-Id: Iff631a638dceec10aa38add88ba93a63a831a574 Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
Diffstat (limited to 'src/corelib/io')
-rw-r--r--src/corelib/io/qfsfileengine_unix.cpp21
1 files changed, 9 insertions, 12 deletions
diff --git a/src/corelib/io/qfsfileengine_unix.cpp b/src/corelib/io/qfsfileengine_unix.cpp
index 03f29f8..c81634c 100644
--- a/src/corelib/io/qfsfileengine_unix.cpp
+++ b/src/corelib/io/qfsfileengine_unix.cpp
@@ -191,18 +191,15 @@ bool QFSFileEnginePrivate::nativeOpen(QIODevice::OpenMode openMode)
if(openMode & QIODevice::Text)
symbianMode |= EFileStreamText;
- // pre Symbian 9.4, file I/O is always unbuffered, and the enum values don't exist
- if(QSysInfo::symbianVersion() >= QSysInfo::SV_9_4) {
- if (openMode & QFile::Unbuffered) {
- if (openMode & QIODevice::WriteOnly)
- symbianMode |= 0x00001000; //EFileWriteDirectIO;
- // ### Unbuffered read is not used, because it prevents file open in /resource
- // ### and has no obvious benefits
- } else {
- if (openMode & QIODevice::WriteOnly)
- symbianMode |= 0x00000800; //EFileWriteBuffered;
- // use implementation defaults for read buffering
- }
+ if (openMode & QFile::Unbuffered) {
+ if (openMode & QIODevice::WriteOnly)
+ symbianMode |= 0x00001000; //EFileWriteDirectIO;
+ // ### Unbuffered read is not used, because it prevents file open in /resource
+ // ### and has no obvious benefits
+ } else {
+ if (openMode & QIODevice::WriteOnly)
+ symbianMode |= 0x00000800; //EFileWriteBuffered;
+ // use implementation defaults for read buffering
}
// Until Qt supports file sharing, we can't support EFileShareReadersOrWriters safely,