Has anyone tried to compile and run source code from the article ? I've tried it both on MacOS and Windows but result is the same - half CPU time and constant memory growth 
I've tried to use this source like this:
int main(int argc, char **argv)
{
QString str
= "http://ua.fishki.net/picsw/122007/21/video/switch_on.wmv";
RcTcpSocket socket;
http.setSocket(&socket);
http.setHost(url.host());
http.get(url.path(), &file);
RateController controller;
controller.setUploadLimit(512);
controller.setDownloadLimit(2048);
controller.addSocket(&socket);
return app.exec();
}
int main(int argc, char **argv)
{
QCoreApplication app(argc, argv);
QString str = "http://ua.fishki.net/picsw/122007/21/video/switch_on.wmv";
QUrl url(str);
RcTcpSocket socket;
QHttpRequestHeader header("GET", str);
QHttp http;
QFile file("Rate.wmv");
http.setSocket(&socket);
http.setHost(url.host());
http.get(url.path(), &file);
RateController controller;
controller.setUploadLimit(512);
controller.setDownloadLimit(2048);
controller.addSocket(&socket);
return app.exec();
}
To copy to clipboard, switch view to plain text mode
Bookmarks