From 1e09ee5ea8d903c49f2b465f5f459b0746f17a3a Mon Sep 17 00:00:00 2001 From: Giuseppe Scrivano Date: Tue, 26 Jul 2011 12:42:40 +0200 Subject: [PATCH] Do not register redirects when in spider mode. --- src/ChangeLog | 4 ++++ src/retr.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index d394166e..0dbabfa2 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2011-07-26 Giuseppe Scrivano + + * retr.c (retrieve_url): Do not register redirects when in spider mode. + 2011-07-20 Merinov Nikolay * iri.c (remote_to_utf8): Add test for non-ASCII symbols with diff --git a/src/retr.c b/src/retr.c index 2b42454a..54937d86 100644 --- a/src/retr.c +++ b/src/retr.c @@ -878,7 +878,7 @@ retrieve_url (struct url * orig_parsed, const char *origurl, char **file, { register_download (u->url, local_file); - if (redirection_count && 0 != strcmp (origurl, u->url)) + if (!opt.spider && redirection_count && 0 != strcmp (origurl, u->url)) register_redirection (origurl, u->url); if (*dt & TEXTHTML)