I have a very simple GET request, which works fine in Desktop Qt, but no data is returned when I run it on Android:
QNetworkManager m_WebCtrl;
QNetworkReply reply;
QUrl url
("http://www.google.com");
request.setUrl(url);
reply = m_WebCtrl.get(request);
// Infinite loop to watch the data come in
while (1) {
qDebug()<< "Data! " << reply->bytesAvailable();
}
QNetworkManager m_WebCtrl;
QNetworkReply reply;
QUrl url("http://www.google.com");
request.setUrl(url);
reply = m_WebCtrl.get(request);
// Infinite loop to watch the data come in
while (1) {
qDebug()<< "Data! " << reply->bytesAvailable();
}
To copy to clipboard, switch view to plain text mode
The Android device has an IP address that is in the valid range. I don't see any errors with reply->error(). What can this be related to?
Edit: I should add that I'm using Qt 5.4 beta.
Bookmarks