Ticket #5189: speedlimit_3658.patch

File speedlimit_3658.patch, 673 bytes (added by Paolo Zambotti, 10 years ago)

speed limit patch for svn revision 3658

  • src/engine/ratelimiter.cpp

     
    6060    {
    6161        ret = m_pOptions->GetOptionVal(OPTION_SPEEDLIMIT_INBOUND + direction) * 1024;
    6262    }
     63    else
     64    {
     65      ret = 0;
     66    }
    6367
    6468    return ret;
    6569}
     
    147151        if (!m_objectList.size())
    148152            continue;
    149153
    150         wxLongLong limit = GetLimit((enum rate_direction)i);
     154        wxLongLong limit = GetLimit((enum rate_direction)i) / 1024;
    151155        if (limit == 0)
    152156        {
    153157            for (std::list<CRateLimiterObject*>::iterator iter = m_objectList.begin(); iter != m_objectList.end(); iter++)