Re: Making Linkchecker working parallel

On Mon, 2005-08-29 at 19:01 +0900, olivier Thereaux wrote:

> I have started moving code in this direction, see rev 4.22 of 
> bin/checklink. It is not great code at all (and I blame it partially on 
> a nasty virus numbing and dumbing me down even more than usual...) but 
> hopefully it's a starting point.
> 
> Ville, Dom, you had expressed a wish to play with such code, please 
> tell me if you're doing any modification and planning a commit, so that 
> I know if I should proceed to cleaning up my code within the next few 
> days, time permitting.

Go ahead, I have no commits pending.

One comment about the patch, though, it contains a few argument
assignments like:

  -  my ($testing, $uri, $want_links, $links, $redirects) = @_;
  +  my ($testing, @links_to_check, $want_links, $links, $redirects) = @_;

It's dangerous to use an array in the middle of the arguments like that.
A quick fix would be to pass @links_to_check as an array ref instead.
Witness:

  sub foo {
    my ($foo, @bar, $quux, $baz) = @_;
    print "@bar\n";
  }
  foo(1, 2, 3, 4, 5, 6, 7);

...prints:

  2 3 4 5 6 7

Received on Tuesday, 30 August 2005 13:34:57 UTC