[70142] trunk/base/src/port1.0/portfetch.tcl

jmr at macports.org jmr at macports.org
Fri Jul 30 04:01:19 PDT 2010


Revision: 70142
          http://trac.macports.org/changeset/70142
Author:   jmr at macports.org
Date:     2010-07-30 04:01:18 -0700 (Fri, 30 Jul 2010)
Log Message:
-----------
remove the sourceforge hack introduced in r17197 since SF seems to have mended its ways

Revision Links:
--------------
    http://trac.macports.org/changeset/17197

Modified Paths:
--------------
    trunk/base/src/port1.0/portfetch.tcl

Modified: trunk/base/src/port1.0/portfetch.tcl
===================================================================
--- trunk/base/src/port1.0/portfetch.tcl	2010-07-30 10:39:12 UTC (rev 70141)
+++ trunk/base/src/port1.0/portfetch.tcl	2010-07-30 11:01:18 UTC (rev 70142)
@@ -477,29 +477,10 @@
             foreach site $urlmap($url_var) {
                 ui_msg "$UI_PREFIX [format [msgcat::mc "Attempting to fetch %s from %s"] $distfile $site]"
                 set file_url [portfetch::assemble_url $site $distfile]
-                set effectiveURL ""
-                if {![catch {eval curl fetch --effective-url effectiveURL $fetch_options {$file_url} {"${distpath}/${distfile}.TMP"}} result] &&
+                if {![catch {eval curl fetch $fetch_options {$file_url} {"${distpath}/${distfile}.TMP"}} result] &&
                     ![catch {file rename -force "${distpath}/${distfile}.TMP" "${distpath}/${distfile}"} result]} {
-
-                    # Special hack to check for sourceforge mirrors, which don't return a proper error code on failure
-                    if {![string equal $effectiveURL $file_url] &&
-                        [string match "http://*sourceforge.net/*" $file_url] &&
-                        [string match "http://*sourceforge.net/projects/*/files/" $effectiveURL]} {
-
-                        # *SourceForge hackage in effect*
-                        # The url seen by curl seems to have been a redirect to the sourceforge mirror page
-                        ui_debug "[msgcat::mc "Fetching from sourceforge mirror failed"]"
-                        file delete -force "${distpath}/${distfile}.TMP"
-
-                        # Continue on to try the next mirror, if any
-                    } else {
-
-                        # Successful fetch
-                        set fetched 1
-                        break
-
-                    }
-
+                    set fetched 1
+                    break
                 } else {
                     ui_debug "[msgcat::mc "Fetching failed:"]: $result"
                     file delete -force "${distpath}/${distfile}.TMP"
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20100730/3d1678bd/attachment.html>


More information about the macports-changes mailing list