From cb854bd4ccda3673896f1cea141c2eb0f1d6a33f Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Tue, 18 Mar 2008 19:33:08 +0000 Subject: [PATCH] #798: 1.06's handling of tracker http 301 redirects can cause a huge strain on tracker --- libtransmission/tracker.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/libtransmission/tracker.c b/libtransmission/tracker.c index 3d7c9c123..75e3ad349 100644 --- a/libtransmission/tracker.c +++ b/libtransmission/tracker.c @@ -512,11 +512,12 @@ onTrackerResponse( struct evhttp_request * req, void * vhash ) } else if( 300<=responseCode && responseCode<=399 ) { - dbgmsg( t, "got a redirect; retrying immediately" ); + const int interval = 20; + dbgmsg( t, "got a redirect. retrying in %d seconds", interval ); /* it's a redirect... updateAddresses() has already * parsed the redirect, all that's left is to retry */ - t->reannounceAt = time( NULL ); + t->reannounceAt = time( NULL ) + interval; t->manualAnnounceAllowedAt = time( NULL ) + t->announceMinIntervalSec; } else if( 400<=responseCode && responseCode<=499 )