From: Adam Dickmeiss Date: Fri, 29 Jun 2001 22:25:55 +0000 (+0000) Subject: Yet another fix regarding relative links. X-Git-Tag: ZMBOT.0.1~18 X-Git-Url: http://sru.miketaylor.org.uk/cgi-bin?a=commitdiff_plain;h=0c2ddebb45112314921d3da60f466622b7e53845;p=tclrobot.git Yet another fix regarding relative links. --- diff --git a/robot.tcl b/robot.tcl index 6323bc3..c9388bc 100755 --- a/robot.tcl +++ b/robot.tcl @@ -1,5 +1,5 @@ #!/usr/bin/tclsh -# $Id: robot.tcl,v 1.19 2001/06/29 21:47:31 adam Exp $ +# $Id: robot.tcl,v 1.20 2001/06/29 22:25:55 adam Exp $ # proc RobotFileNext1 {area lead} { # puts "RobotFileNext1 area=$area lead=$lead" @@ -323,8 +323,9 @@ proc RobotHref {url hrefx hostx pathx} { switch -- $c { .. { if {$pathl > 0} { - incr pathl -1 + incr pathl -2 set path [lrange $path 0 $pathl] + incr pathl } } . { @@ -637,7 +638,6 @@ proc Robot200 {url} { proc RobotReadContent {url sock binary} { global URL - puts "RobotReadContent $url" set buffer [read $sock 16384] set readCount [string length $buffer]