Updated 2016-05-19 21:57:59 by steveL

Dos http::geturl methods with channel option has bug in it?

Test this. The file downloaded has extra stuff in it at the top and the end:

package req Tk package req http

proc test {} { set url "http://hintjens.com/blog:119"

set chan [open "downloaded" w]

set token [::http::geturl $url -channel $chan]

if {$token == ""} {
 close $chan
 exit

} else {
  flush $chan
  close $chan
  http::cleanup $token

}

puts "open downloaded in editor"

}