~ubuntu-branches/ubuntu/quantal/aria2/quantal

« back to all changes in this revision

Viewing changes to src/SegmentMan.cc

  • Committer: Bazaar Package Importer
  • Author(s): Kartik Mistry
  • Date: 2011-04-02 12:38:55 UTC
  • mfrom: (2.5.2 sid)
  • Revision ID: james.westby@ubuntu.com-20110402123855-znkslovhf5qvkjut
Tags: 1.11.1-1
New upstream release

Show diffs side-by-side

added added

removed removed

Lines of Context:
404
404
unsigned int SegmentMan::calculateDownloadSpeed()
405
405
{
406
406
  unsigned int speed = 0;
407
 
  if(lastPeerStatDlspdMapUpdated_.differenceInMillis(global::wallclock) >= 250){
 
407
  if(lastPeerStatDlspdMapUpdated_.differenceInMillis(global::wallclock)+
 
408
     A2_DELTA_MILLIS >= 250){
408
409
    lastPeerStatDlspdMapUpdated_ = global::wallclock;
409
410
    peerStatDlspdMap_.clear();
410
411
    for(std::vector<SharedHandle<PeerStat> >::const_iterator i =