in reply to Re^5: Parallel downloading under Win32?
in thread Parallel downloading under Win32?

Thank you!

I had no idea something like that exists.

After reading up on IPC::Open2, this works perfectly:
use IPC::Open2; for my $id (@ids) { $wgets++; push @pids, open2(undef, undef, 'wget', $url.$id, '-q', '-O', +$dir.$id); while ( @pids >= 10 ) { waitpid( shift @pids, 0 ); } } while ( @pids ) { waitpid( shift @pids, 0 ); }
And as far as i can tell, it'll be completely cross-platform-compatible, as long as i provide wget.exe. :)