diff options
author | Daniel Friesel <derf@derf.homelinux.org> | 2010-05-20 19:37:23 +0200 |
---|---|---|
committer | Daniel Friesel <derf@derf.homelinux.org> | 2010-05-20 19:37:23 +0200 |
commit | 2423115b919f4c11c8eddc96667e987e33cef13a (patch) | |
tree | 8cbb1d585e5e4fb98905012f08f6b002738251fc | |
parent | 8abb5a7bbf57e6963816753d52aae400e9740285 (diff) |
Fix loop detection
-rwxr-xr-x | bin/comirror | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/bin/comirror b/bin/comirror index d03e3af..a099212 100755 --- a/bin/comirror +++ b/bin/comirror @@ -35,11 +35,12 @@ while ( and $mech->status() == 200 ) { - say $mech->uri(); + say $mech->uri->as_string; + say $uri; - $uri = find_next_link->url(); + $uri = find_next_link->URI->abs->as_string; - if ($uri == $mech->uri) { + if ($uri eq $mech->uri->as_string) { die("Looks like we're in a loop, bailing out\n"); } |