diff options
author | Martin Jones <martin.jones@nokia.com> | 2010-02-04 22:46:42 (GMT) |
---|---|---|
committer | Martin Jones <martin.jones@nokia.com> | 2010-02-04 22:46:42 (GMT) |
commit | a4e3ee5296397c0111cc585696b0aca587509dbf (patch) | |
tree | 499dc5a42aa62395df3eb80fe368dabf19ad010d /tools/qmlviewer | |
parent | b83610a567c031f10d565a64edd4cb8b4d55a53a (diff) | |
download | Qt-a4e3ee5296397c0111cc585696b0aca587509dbf.zip Qt-a4e3ee5296397c0111cc585696b0aca587509dbf.tar.gz Qt-a4e3ee5296397c0111cc585696b0aca587509dbf.tar.bz2 |
Make sure cookies are saved.
Diffstat (limited to 'tools/qmlviewer')
-rw-r--r-- | tools/qmlviewer/qmlviewer.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tools/qmlviewer/qmlviewer.cpp b/tools/qmlviewer/qmlviewer.cpp index 2b69d97..7aa3a40 100644 --- a/tools/qmlviewer/qmlviewer.cpp +++ b/tools/qmlviewer/qmlviewer.cpp @@ -344,12 +344,15 @@ class NetworkAccessManagerFactory : public QmlNetworkAccessManagerFactory { public: NetworkAccessManagerFactory() : cookieJar(0), cacheSize(0) {} + ~NetworkAccessManagerFactory() { + delete cookieJar; + } QNetworkAccessManager *create(QObject *parent) { QMutexLocker lock(&mutex); QNetworkAccessManager *manager = new QNetworkAccessManager(parent); if (!cookieJar) - cookieJar = new PersistentCookieJar(manager); + cookieJar = new PersistentCookieJar(0); manager->setCookieJar(cookieJar); cookieJar->setParent(0); setupProxy(manager); |