fix sourceforge mirrors, thx d1mag
[openwrt-10.03/.git] / scripts / download.pl
index 08caa03e78135ff209161f07d2c85bd429150091..43dc7965b87e50f219080d8e22f3ad33227e5784 100755 (executable)
@@ -57,9 +57,9 @@ sub cleanup
 foreach my $mirror (@ARGV) {
        if ($mirror =~ /^\@SF\/(.+)$/) {
                my $sfpath = $1;
-               open SF, "wget -t1 -q -O- 'http://prdownloads.sf.net/$sfpath/$filename' |";
+               open SF, "wget -t1 -q -O- 'http://prdownloads.sourceforge.net/$sfpath/$filename' |";
                while (<SF>) {
-                       /RADIO NAME=use_default VALUE=(\w+) OnClick="form\.submit\(\)">/ and do {
+                       /type="radio" name="use_default" value="(\w+)" onclick="form\.submit\(\)"\/>/ and do {
                                push @mirrors, "http://$1.dl.sourceforge.net/sourceforge/$sfpath";
                        };
                }
@@ -75,8 +75,8 @@ foreach my $mirror (@ARGV) {
        }
 }
 
-push @mirrors, 'http://mirror1.openwrt.org/';
-push @mirrors, 'http://mirror2.openwrt.org/';
+#push @mirrors, 'http://mirror1.openwrt.org/';
+#push @mirrors, 'http://mirror2.openwrt.org/';
 push @mirrors, 'http://downloads.openwrt.org/sources/';
 
 while (!$ok) {