summaryrefslogtreecommitdiffstats
path: root/src/network
diff options
context:
space:
mode:
authorOlivier Goffart <ogoffart@trolltech.com>2009-04-15 09:19:56 (GMT)
committerOlivier Goffart <ogoffart@trolltech.com>2009-04-15 09:19:56 (GMT)
commit21099dac569348a15df2d6a5a61015b5afa17097 (patch)
treeb4ae338f206666b7f07e1f78278ad6d38609880b /src/network
parentf169ca1020886707b04101300e365d79f38a6332 (diff)
parent4e78de5a4281bd1c27a984b13887975798573aae (diff)
downloadQt-21099dac569348a15df2d6a5a61015b5afa17097.zip
Qt-21099dac569348a15df2d6a5a61015b5afa17097.tar.gz
Qt-21099dac569348a15df2d6a5a61015b5afa17097.tar.bz2
Merge commit 'origin/4.5'
Conflicts: src/gui/graphicsview/qgraphicsitem.cpp
Diffstat (limited to 'src/network')
-rw-r--r--src/network/access/qhttpnetworkreply_p.h10
-rw-r--r--src/network/access/qnetworkdiskcache.cpp3
2 files changed, 6 insertions, 7 deletions
diff --git a/src/network/access/qhttpnetworkreply_p.h b/src/network/access/qhttpnetworkreply_p.h
index 21f4116..c17c65c 100644
--- a/src/network/access/qhttpnetworkreply_p.h
+++ b/src/network/access/qhttpnetworkreply_p.h
@@ -66,12 +66,10 @@ static const unsigned char gz_magic[2] = {0x1f, 0x8b}; // gzip magic header
#define CHUNK 16384
#endif
-#ifndef QT_NO_OPENSSL
-# include <QtNetwork/qsslsocket.h>
-# include <QtNetwork/qsslerror.h>
-#else
-# include <QtNetwork/qtcpsocket.h>
-#endif
+#include <QtNetwork/qtcpsocket.h>
+// it's safe to include these even if SSL support is not enabled
+#include <QtNetwork/qsslsocket.h>
+#include <QtNetwork/qsslerror.h>
#include <QtNetwork/qnetworkrequest.h>
#include <QtNetwork/qnetworkreply.h>
diff --git a/src/network/access/qnetworkdiskcache.cpp b/src/network/access/qnetworkdiskcache.cpp
index e472b9d..14a04f1 100644
--- a/src/network/access/qnetworkdiskcache.cpp
+++ b/src/network/access/qnetworkdiskcache.cpp
@@ -255,7 +255,8 @@ void QNetworkDiskCachePrivate::storeItem(QCacheItem *cacheItem)
// ### use atomic rename rather then remove & rename
if (cacheItem->file->rename(fileName))
currentCacheSize += cacheItem->file->size();
- cacheItem->file->setAutoRemove(true);
+ else
+ cacheItem->file->setAutoRemove(true);
}
if (cacheItem->metaData.url() == lastItem.metaData.url())
lastItem.reset();