[38163] trunk/base/src/port1.0/portfetch.tcl
jmr at macports.org
jmr at macports.org
Wed Jul 9 18:50:58 PDT 2008
Revision: 38163
http://trac.macosforge.org/projects/macports/changeset/38163
Author: jmr at macports.org
Date: 2008-07-09 18:50:57 -0700 (Wed, 09 Jul 2008)
Log Message:
-----------
In fetch, gracefully handle failure to spawn ping processes. (#15906)
Modified Paths:
--------------
trunk/base/src/port1.0/portfetch.tcl
Modified: trunk/base/src/port1.0/portfetch.tcl
===================================================================
--- trunk/base/src/port1.0/portfetch.tcl 2008-07-09 23:23:52 UTC (rev 38162)
+++ trunk/base/src/port1.0/portfetch.tcl 2008-07-10 01:50:57 UTC (rev 38163)
@@ -361,10 +361,15 @@
}
}
if { ![info exists seen($host)] } {
- set seen($host) yes
- lappend hosts $host
- ui_debug "Pinging $host..."
- set fds($host) [open "|ping -noq -c3 -t3 $host | grep round-trip | cut -d / -f 5"]
+ if {[catch {set fds($host) [open "|ping -noq -c3 -t3 $host | grep round-trip | cut -d / -f 5"]}]} {
+ ui_debug "Spawning ping for $host failed"
+ # will end up after all hosts that were pinged OK but before those that didn't respond
+ set pingtimes($host) 5000
+ } else {
+ ui_debug "Pinging $host..."
+ set seen($host) yes
+ lappend hosts $host
+ }
}
}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/macports-changes/attachments/20080709/b8f9599f/attachment.html
More information about the macports-changes
mailing list