mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-12-18 07:24:07 +00:00
Websites: Fix some redirects
This commit is contained in:
parent
79f05a23c8
commit
3bcd9cfe37
|
@ -200,9 +200,10 @@ void WebSiteArticleRequest::requestFinished( QNetworkReply * r )
|
||||||
QUrl redirectUrl = possibleRedirectUrl.toUrl();
|
QUrl redirectUrl = possibleRedirectUrl.toUrl();
|
||||||
if( !redirectUrl.isEmpty() )
|
if( !redirectUrl.isEmpty() )
|
||||||
{
|
{
|
||||||
|
QUrl newUrl = netReply->url().resolved( redirectUrl );
|
||||||
disconnect( netReply, 0, 0, 0 );
|
disconnect( netReply, 0, 0, 0 );
|
||||||
netReply->deleteLater();
|
netReply->deleteLater();
|
||||||
netReply = mgr.get( QNetworkRequest( redirectUrl ) );
|
netReply = mgr.get( QNetworkRequest( newUrl ) );
|
||||||
#ifndef QT_NO_OPENSSL
|
#ifndef QT_NO_OPENSSL
|
||||||
connect( netReply, SIGNAL( sslErrors( QList< QSslError > ) ),
|
connect( netReply, SIGNAL( sslErrors( QList< QSslError > ) ),
|
||||||
netReply, SLOT( ignoreSslErrors() ) );
|
netReply, SLOT( ignoreSslErrors() ) );
|
||||||
|
|
Loading…
Reference in a new issue