summaryrefslogtreecommitdiffstats
path: root/tests/auto/qsslsocket/tst_qsslsocket.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/qsslsocket/tst_qsslsocket.cpp')
-rw-r--r--tests/auto/qsslsocket/tst_qsslsocket.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/auto/qsslsocket/tst_qsslsocket.cpp b/tests/auto/qsslsocket/tst_qsslsocket.cpp
index b508d4795b..576f2f6f0d 100644
--- a/tests/auto/qsslsocket/tst_qsslsocket.cpp
+++ b/tests/auto/qsslsocket/tst_qsslsocket.cpp
@@ -1561,12 +1561,13 @@ protected:
#else
bool ret = server.waitForNewConnection(20000);
#endif
+ Q_UNUSED(ret);
// delayed start of encryption
QTest::qSleep(100);
QSslSocket *socket = server.socket;
- QVERIFY(socket);
- QVERIFY(socket->isValid());
+ if (!socket || !socket->isValid())
+ return; // error
socket->ignoreSslErrors();
socket->startServerEncryption();
if (!socket->waitForEncrypted(2000))
@@ -1955,7 +1956,7 @@ void tst_QSslSocket::writeBigChunk()
QByteArray data;
data.resize(1024*1024*10); // 10 MB
// init with garbage. needed so ssl cannot compress it in an efficient way.
- for (int i = 0; i < data.size() / sizeof(int); i++) {
+ for (size_t i = 0; i < data.size() / sizeof(int); i++) {
int r = qrand();
data.data()[i*sizeof(int)] = r;
}