fix: change macro QT_NO_OPENSSL to QT_NO_SSL

This commit is contained in:
xiaoyifang 2022-12-15 15:11:09 +08:00
parent 58a0bc74af
commit 08c0df49e1
5 changed files with 11 additions and 11 deletions

View file

@ -242,7 +242,7 @@ QNetworkReply * ArticleNetworkAccessManager::getArticleReply( QNetworkRequest co
if( url.scheme() == "https") if( url.scheme() == "https")
{ {
#ifndef QT_NO_OPENSSL #ifndef QT_NO_SSL
connect( reply, SIGNAL( sslErrors( QList< QSslError > ) ), connect( reply, SIGNAL( sslErrors( QList< QSslError > ) ),
reply, SLOT( ignoreSslErrors() ) ); reply, SLOT( ignoreSslErrors() ) );
#endif #endif

View file

@ -82,7 +82,7 @@ using std::wstring;
using std::map; using std::map;
using std::pair; using std::pair;
#ifndef QT_NO_OPENSSL #ifndef QT_NO_SSL
class InitSSLRunnable : public QRunnable class InitSSLRunnable : public QRunnable
{ {
@ -157,7 +157,7 @@ MainWindow::MainWindow( Config::Class & cfg_ ):
if( QThreadPool::globalInstance()->maxThreadCount() < MIN_THREAD_COUNT ) if( QThreadPool::globalInstance()->maxThreadCount() < MIN_THREAD_COUNT )
QThreadPool::globalInstance()->setMaxThreadCount( MIN_THREAD_COUNT ); QThreadPool::globalInstance()->setMaxThreadCount( MIN_THREAD_COUNT );
#ifndef QT_NO_OPENSSL #ifndef QT_NO_SSL
QThreadPool::globalInstance()->start( new InitSSLRunnable ); QThreadPool::globalInstance()->start( new InitSSLRunnable );
#endif #endif

View file

@ -135,7 +135,7 @@ MediaWikiWordSearchRequest::MediaWikiWordSearchRequest( wstring const & str,
connect( netReply.get(), SIGNAL( finished() ), connect( netReply.get(), SIGNAL( finished() ),
this, SLOT( downloadFinished() ) ); this, SLOT( downloadFinished() ) );
#ifndef QT_NO_OPENSSL #ifndef QT_NO_SSL
connect( netReply.get(), SIGNAL( sslErrors( QList< QSslError > ) ), connect( netReply.get(), SIGNAL( sslErrors( QList< QSslError > ) ),
netReply.get(), SLOT( ignoreSslErrors() ) ); netReply.get(), SLOT( ignoreSslErrors() ) );
@ -279,7 +279,7 @@ void MediaWikiArticleRequest::addQuery( QNetworkAccessManager & mgr,
connect( netReply, &QNetworkReply::errorOccurred, this, [=](QNetworkReply::NetworkError e){ connect( netReply, &QNetworkReply::errorOccurred, this, [=](QNetworkReply::NetworkError e){
qDebug()<< "error:"<<e; qDebug()<< "error:"<<e;
} ); } );
#ifndef QT_NO_OPENSSL #ifndef QT_NO_SSL
connect( netReply, SIGNAL( sslErrors( QList< QSslError > ) ), connect( netReply, SIGNAL( sslErrors( QList< QSslError > ) ),
netReply, SLOT( ignoreSslErrors() ) ); netReply, SLOT( ignoreSslErrors() ) );

View file

@ -15,7 +15,7 @@ redirectCount( 0 )
reply = mgr.get( QNetworkRequest( url ) ); reply = mgr.get( QNetworkRequest( url ) );
#ifndef QT_NO_OPENSSL #ifndef QT_NO_SSL
connect( reply, SIGNAL( sslErrors( QList< QSslError > ) ), connect( reply, SIGNAL( sslErrors( QList< QSslError > ) ),
reply, SLOT( ignoreSslErrors() ) ); reply, SLOT( ignoreSslErrors() ) );
#endif #endif
@ -52,7 +52,7 @@ void WebMultimediaDownload::replyFinished( QNetworkReply * r )
} }
reply = mgr.get( QNetworkRequest( redirectUrl ) ); reply = mgr.get( QNetworkRequest( redirectUrl ) );
#ifndef QT_NO_OPENSSL #ifndef QT_NO_SSL
connect( reply, SIGNAL( sslErrors( QList< QSslError > ) ), connect( reply, SIGNAL( sslErrors( QList< QSslError > ) ),
reply, SLOT( ignoreSslErrors() ) ); reply, SLOT( ignoreSslErrors() ) );
#endif #endif

View file

@ -140,7 +140,7 @@ WebSiteArticleRequest::WebSiteArticleRequest( QString const & url_,
request.setAttribute( QNetworkRequest::RedirectPolicyAttribute, QNetworkRequest::NoLessSafeRedirectPolicy ); request.setAttribute( QNetworkRequest::RedirectPolicyAttribute, QNetworkRequest::NoLessSafeRedirectPolicy );
netReply = mgr.get( request ); netReply = mgr.get( request );
#ifndef QT_NO_OPENSSL #ifndef QT_NO_SSL
connect( netReply, SIGNAL( sslErrors( QList< QSslError > ) ), connect( netReply, SIGNAL( sslErrors( QList< QSslError > ) ),
netReply, SLOT( ignoreSslErrors() ) ); netReply, SLOT( ignoreSslErrors() ) );
#endif #endif
@ -173,7 +173,7 @@ void WebSiteArticleRequest::requestFinished( QNetworkReply * r )
disconnect( netReply, 0, 0, 0 ); disconnect( netReply, 0, 0, 0 );
netReply->deleteLater(); netReply->deleteLater();
netReply = mgr.get( QNetworkRequest( redirectUrl ) ); netReply = mgr.get( QNetworkRequest( redirectUrl ) );
#ifndef QT_NO_OPENSSL #ifndef QT_NO_SSL
connect( netReply, SIGNAL( sslErrors( QList< QSslError > ) ), connect( netReply, SIGNAL( sslErrors( QList< QSslError > ) ),
netReply, SLOT( ignoreSslErrors() ) ); netReply, SLOT( ignoreSslErrors() ) );
#endif #endif
@ -449,7 +449,7 @@ WebSiteResourceRequest::WebSiteResourceRequest( QString const & url_,
netReply = mgr.get( QNetworkRequest( reqUrl ) ); netReply = mgr.get( QNetworkRequest( reqUrl ) );
#ifndef QT_NO_OPENSSL #ifndef QT_NO_SSL
connect( netReply, SIGNAL( sslErrors( QList< QSslError > ) ), connect( netReply, SIGNAL( sslErrors( QList< QSslError > ) ),
netReply, SLOT( ignoreSslErrors() ) ); netReply, SLOT( ignoreSslErrors() ) );
#endif #endif
@ -482,7 +482,7 @@ void WebSiteResourceRequest::requestFinished( QNetworkReply * r )
disconnect( netReply, 0, 0, 0 ); disconnect( netReply, 0, 0, 0 );
netReply->deleteLater(); netReply->deleteLater();
netReply = mgr.get( QNetworkRequest( redirectUrl ) ); netReply = mgr.get( QNetworkRequest( redirectUrl ) );
#ifndef QT_NO_OPENSSL #ifndef QT_NO_SSL
connect( netReply, SIGNAL( sslErrors( QList< QSslError > ) ), connect( netReply, SIGNAL( sslErrors( QList< QSslError > ) ),
netReply, SLOT( ignoreSslErrors() ) ); netReply, SLOT( ignoreSslErrors() ) );
#endif #endif