From 3fe79f23a97323521eb0182f8b46b0d0fc9ce44b Mon Sep 17 00:00:00 2001 From: Shane Kearns Date: Mon, 20 Feb 2012 16:40:55 +0000 Subject: Make qget manual test compile without ssl support Change-Id: I35f92328b79df1cfcae52fa6ff8290f260183aea Reviewed-by: Richard J. Moore --- tests/manual/qnetworkaccessmanager/qget/qget.cpp | 4 ++++ tests/manual/qnetworkaccessmanager/qget/qget.h | 2 ++ 2 files changed, 6 insertions(+) (limited to 'tests') diff --git a/tests/manual/qnetworkaccessmanager/qget/qget.cpp b/tests/manual/qnetworkaccessmanager/qget/qget.cpp index 86b05f8afe..44fb62150b 100644 --- a/tests/manual/qnetworkaccessmanager/qget/qget.cpp +++ b/tests/manual/qnetworkaccessmanager/qget/qget.cpp @@ -57,7 +57,9 @@ DownloadManager::DownloadManager() connect(&nam, SIGNAL(finished(QNetworkReply*)), this, SLOT(finished(QNetworkReply*))); connect(&nam, SIGNAL(authenticationRequired(QNetworkReply*, QAuthenticator*)), this, SLOT(authenticationRequired(QNetworkReply*, QAuthenticator*))); connect(&nam, SIGNAL(proxyAuthenticationRequired(const QNetworkProxy&, QAuthenticator*)), this, SLOT(proxyAuthenticationRequired(const QNetworkProxy&, QAuthenticator*))); +#ifndef QT_NO_SSL connect(&nam, SIGNAL(sslErrors(QNetworkReply*, const QList&)), this, SLOT(sslErrors(QNetworkReply*, const QList&))); +#endif } DownloadManager::~DownloadManager() @@ -117,6 +119,7 @@ void DownloadManager::proxyAuthenticationRequired(const QNetworkProxy& proxy, QA } } +#ifndef QT_NO_SSL void DownloadManager::sslErrors(QNetworkReply* reply, const QList& errors) { qDebug() << "sslErrors"; @@ -125,6 +128,7 @@ void DownloadManager::sslErrors(QNetworkReply* reply, const QList& er qDebug() << error.certificate().toPem(); } } +#endif DownloadItem::DownloadItem(QNetworkReply* r, QNetworkAccessManager& manager) : reply(r), nam(manager) { diff --git a/tests/manual/qnetworkaccessmanager/qget/qget.h b/tests/manual/qnetworkaccessmanager/qget/qget.h index c8ab9e3a44..40d75a3903 100644 --- a/tests/manual/qnetworkaccessmanager/qget/qget.h +++ b/tests/manual/qnetworkaccessmanager/qget/qget.h @@ -87,7 +87,9 @@ private slots: void finished(QNetworkReply* reply); void authenticationRequired(QNetworkReply* reply, QAuthenticator* authenticator); void proxyAuthenticationRequired(const QNetworkProxy& proxy, QAuthenticator* authenticator); +#ifndef QT_NO_SSL void sslErrors(QNetworkReply* reply, const QList& errors); +#endif void downloadFinished(DownloadItem *item); private: QNetworkAccessManager nam; -- cgit v1.2.3