| View previous topic :: View next topic |
| Author |
Message |
speechles Revered One

Joined: 26 Aug 2006 Posts: 1398 Location: emerald triangle, california (coastal redwoods)
|
Posted: Fri Dec 14, 2007 8:46 pm Post subject: |
|
|
| De Kus wrote: | | no nice way imho, they could first check if exists state(after) to prevent occurance of unneccessary TCL errors. | Testing this theory it seems to work...
lines 165,166 change to: | Code: | if {[info exists state(sock)]} { catch {close $state(sock)} }
if {[info exists state(after)]} { catch {after cancel $state(after)} } |
lines 197,198 change to: | Code: | if {[info exists state(sock)]} { catch {fileevent $state(sock) readable {}} }
if {[info exists state(sock)]} { catch {fileevent $state(sock) writable {}} } |
Using HTTP 2.4.2 and changing the lines above it seems to solve the problem. Running various http queries and a quick .set errrorInfo afterwards yields the following... | Quote: | <speechles> !g google
<sp33chy> 1,460,000,000 Results | Google @ http://www.google.com/ | Google Maps @ http://maps.google.com/ | Google Video @ http://video.google.com/ | Google Groups @ http://groups.google.com/
*meanwhile on the partyline directly after*
<speechles> .set errorInfo
<sp33chy> Currently: couldn't create error file for command: no such file or directory
<sp33chy> Currently: while executing
<sp33chy> Currently: "exec chmod 700 $nb_dir"
<speechles> !w .jasd asd
<sp33chy> Socket Error accessing 'jasd.wikipedia.org' .. Does it exist?
*meanwhile on the partyline directly after*
<speechles> .set errorInfo
<sp33chy> Currently: couldn't open socket: host is unreachable
<sp33chy> Currently: while executing
<sp33chy> Currently: "::http::geturl $query -timeout [expr 1000 * 5]" |
Notice the top error message which is usually a state(after) error is instead an error message reporting no error found to report, so this does work as a fix. If someone can shed some light if this is indeed an http package bug it would be wonderful.  |
|
| Back to top |
|
 |
Alchera Revered One

Joined: 11 Aug 2003 Posts: 3344 Location: Ballarat Victoria, Australia
|
Posted: Fri Dec 14, 2007 11:47 pm Post subject: |
|
|
I use only one script that grabs data from the web (and causes this annoyance), the OV2 version of B0unTy's iMDB.tcl.
It uses:
| Code: | | ::http::Finish $page |
_________________ Add [SOLVED] to the thread title if your issue has been.
Search | FAQ | RTM |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|