fdservices
IS-IT--Management
I have an simple script which opens a file, reads it and puts each line, until it reaches an eof and then closes.
This is then called by other scripts which are performing actions and logging the results. So the first script reads the log, as it is written, and displays the progress.
Up until now this has worked fine, but with 8.6 it has stopped working and just hangs after a few lines of output. I have read about blocking but the examples shown in the manual make no difference to the results e.g.
What am I missing?
Andrew
This is then called by other scripts which are performing actions and logging the results. So the first script reads the log, as it is written, and displays the progress.
Up until now this has worked fine, but with 8.6 it has stopped working and just hangs after a few lines of output. I have read about blocking but the examples shown in the manual make no difference to the results e.g.
Code:
proc GetData {chan} {
if {[gets $chan line] >= 0} {
puts $line
}
if {[eof $chan]} {
close $chan
}
}
fconfigure $chan -blocking 0 -buffering line -translation crlf
fileevent $chan readable [list GetData $chan]
What am I missing?
Andrew