summaryrefslogtreecommitdiffstats
path: root/src/corelib/io/qresource.cpp
diff options
context:
space:
mode:
authoraxis <qt-info@nokia.com>2009-08-21 13:23:42 (GMT)
committeraxis <qt-info@nokia.com>2009-08-21 13:23:42 (GMT)
commit044680951401487590c0ed554092dd9b7e0ee783 (patch)
treeed2492ad2fd49481148fdd7a1486cbf197c9bfe7 /src/corelib/io/qresource.cpp
parentab1df6dea670a60bfef5efd81d6687f9534cfc5d (diff)
parent00ba962d428dcdff70fcde74a9e5cb316545cef6 (diff)
downloadQt-044680951401487590c0ed554092dd9b7e0ee783.zip
Qt-044680951401487590c0ed554092dd9b7e0ee783.tar.gz
Qt-044680951401487590c0ed554092dd9b7e0ee783.tar.bz2
Merge branch 'master' of git@scm.dev.nokia.troll.no:qt/qt
Conflicts: src/corelib/io/qprocess.h
Diffstat (limited to 'src/corelib/io/qresource.cpp')
-rw-r--r--src/corelib/io/qresource.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/corelib/io/qresource.cpp b/src/corelib/io/qresource.cpp
index ab4a7b7..ff1a31f 100644
--- a/src/corelib/io/qresource.cpp
+++ b/src/corelib/io/qresource.cpp
@@ -1485,11 +1485,7 @@ uchar *QResourceFileEnginePrivate::map(qint64 offset, qint64 size, QFile::Memory
{
Q_Q(QResourceFileEngine);
Q_UNUSED(flags);
- if (!resource.isValid()
- || offset < 0
- || size < 0
- || offset + size > resource.size()
- || (size == 0)) {
+ if (offset < 0 || size <= 0 || !resource.isValid() || offset + size > resource.size()) {
q->setError(QFile::UnspecifiedError, QString());
return 0;
}