From fdc61b0d0b4daf641985b042d1d45d6e01c9eed9 Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Mon, 31 Aug 2009 17:18:58 +0000 Subject: [PATCH] (trunk libT) #2373: Handle HTTP redirects more gracefully --- libtransmission/tracker.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/libtransmission/tracker.c b/libtransmission/tracker.c index 8014a645a..8cdec0398 100644 --- a/libtransmission/tracker.c +++ b/libtransmission/tracker.c @@ -524,7 +524,12 @@ onTrackerResponse( tr_session * session, responseCode, tr_webGetResponseStr( responseCode ) ); tr_strlcpy( t->lastAnnounceStr, buf, sizeof( t->lastAnnounceStr ) ); - publishWarning( t, buf ); + + /* if the repsonse may require intervention, notify the user; otherwise, just log it */ + if( responseCode >= 400 ) + publishWarning( t, buf ); + tr_ninf( t->name, "%s", buf ); + tr_free( buf ); } else