Closed arrizer closed 12 years ago
The reason for this is the wrong speed and size calculation. It shows > 7 MiB/s, but I have only max 2 MiB/s Already downloaded: 13GB, but file has only 7GB
I believe the flaw is here:
sub downloadFile
{
my $url = shift;
my $filename = shift;
$agent->add_handler(response_header => \&didReceiveResponse);
$agent->add_handler(response_data => \&didReceiveData);
$agent->credentials("put.io:80", "Put.io File Space", $config->{"account_name"}, $config->{"account_password"});
The handler is added every time a file is downloaded, thus it ends up being called several times each tick. The value shown seemed to be pretty close to n*(actual) for the n-th file being downloaded.
The download progress is not calculated correctly for some files.