Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
QNetworkAccessManager::get takes over 1 second
EMC3 last edited by EMC3
I have written this small piece of code:
QNetworkAccessManager * m_netwManager = new QNetworkAccessManager(this); connect(m_netwManager, SIGNAL(finished(QNetworkReply*)), this, SLOT(slot_netwManagerFinished(QNetworkReply*))); qDebug() << "create"; QNetworkRequest request(url); qDebug() << "get"; //why does this take ~1second????????? QNetworkReply * rep = m_netwManager->get(request); qDebug() << "rr f";
It works perfectly. Until now i used QT 5.5.0 and i had no problems doing it in the UI main thread. Now i updated to QT 5.5.1 and the line QNetworkReply * rep = m_netwManager->get(request); blocks for about 1 second. I googled that it is caused by Windows. (see https://bugreports.qt.io/browse/QTBUG-33315). Is there any workaround or do i have to thread my application?
BTW i'm using a static QT version with MinGW64 and OpenSSL linked in on WIN10