diff options
author | Jędrzej Nowacki <jedrzej.nowacki@digia.com> | 2013-11-26 12:41:36 +0000 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-11-28 10:41:22 +0100 |
commit | 870a6e44740dea93c580ff171e909a89d0b71688 (patch) | |
tree | ab31084e7425da5e5cfacf42446dd2eb014f702e /tests/auto/files/tst_files.cpp | |
parent | 2a9204258e01b5164a899ecc42ad6dcd67d6d423 (diff) | |
download | qtenginio-870a6e44740dea93c580ff171e909a89d0b71688.tar.gz |
Fix memory leak in tests.
QNetworkReply should be removed when finished.
Change-Id: Ifb027d634885f4df26a5807c56b8e9f976b82d0b
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
Diffstat (limited to 'tests/auto/files/tst_files.cpp')
-rw-r--r-- | tests/auto/files/tst_files.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/auto/files/tst_files.cpp b/tests/auto/files/tst_files.cpp index eb87525..8ac1924 100644 --- a/tests/auto/files/tst_files.cpp +++ b/tests/auto/files/tst_files.cpp @@ -262,6 +262,7 @@ void tst_Files::fileUploadDownload() QSignalSpy downloadSpy(reply, SIGNAL(finished())); QTRY_COMPARE(downloadSpy.count(), 1); QByteArray imageData = reply->readAll(); + reply->deleteLater(); QImage img = QImage::fromData(imageData); QCOMPARE(img.size(), QSize(181, 54)); } @@ -328,6 +329,7 @@ void tst_Files::fileUploadDownload() QSignalSpy downloadSpy(reply, SIGNAL(finished())); QTRY_COMPARE(downloadSpy.count(), 1); QByteArray imageData = reply->readAll(); + reply->deleteLater(); QImage img = QImage::fromData(imageData); QCOMPARE(img.size(), QSize(20, 20)); } |