1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2024-12-26 01:27:28 +00:00

(libT) #1045: gracefully handle trackers that return a scrape interval that's too low

This commit is contained in:
Charles Kerr 2008-07-02 01:17:57 +00:00
parent 5493046090
commit 70e21e93ff

View file

@ -491,6 +491,11 @@ onScrapeResponse( tr_session * session,
if(( tr_bencDictFindInt( flags, "min_request_interval", &itmp )))
t->scrapeIntervalSec = i;
/* as per ticket #1045, safeguard against trackers returning
* a very low min_request_interval... */
if( t->scrapeIntervalSec < DEFAULT_SCRAPE_INTERVAL_SEC )
t->scrapeIntervalSec = DEFAULT_SCRAPE_INTERVAL_SEC;
tr_ndbg( t->name, "Scrape successful. Rescraping in %d seconds.",
t->scrapeIntervalSec );