lipk
20th March 2011, 08:41
Hi all!
I have almost become a nervous wreck already because of this thing:
#include <QtCore/QCoreApplication>
#include <QtNetwork>
int main(int argc, char *argv[])
{
QCoreApplication a(argc, argv);
QNetworkAccessManager manager;
QNetworkRequest request(QUrl("http://www.google.hu"));
QNetworkReply *reply = manager.get(request);
qDebug() << reply->errorString();
return a.exec();
}
It's that simple. And it doesn't work. It says: "Unknown error".
Bad code? Bad proxy settings? What? Nokia's HTTP example works fine.
I have almost become a nervous wreck already because of this thing:
#include <QtCore/QCoreApplication>
#include <QtNetwork>
int main(int argc, char *argv[])
{
QCoreApplication a(argc, argv);
QNetworkAccessManager manager;
QNetworkRequest request(QUrl("http://www.google.hu"));
QNetworkReply *reply = manager.get(request);
qDebug() << reply->errorString();
return a.exec();
}
It's that simple. And it doesn't work. It says: "Unknown error".
Bad code? Bad proxy settings? What? Nokia's HTTP example works fine.