At least on Linux, puts is thread-safe if the -nonewline option is used.
I ran tests and used it for a URL logging feature we developed - worked
great.  So instead of puts $string, do puts -nonewline "$string\n"

JIm

>
>  I guess I could start with what you've done, clean up the
> > code, and start looking at what kind of hooks I'd need in order to
> > get the Tcl interpreter to log the same kind of information about
> > indivual proc calls (perhaps even including ALL proc calls) --
> > using an nsv is a great idea that I didn't think of, immediately.
>
> dossy, check out the C functions..
>
> Tcl_CreateTrace()
> Tcl_DeleteTrace()
>
> they will allow you to trace tcl proc calls..
>
> -mike
>
>
> >
> > One concern:  does the nsv implementation use mutexes?  This will
> > affect the way the trace filters must be written to avoid logging
> > lock contention as part of a URL's performance, artificially
> > bloating numbers in a non-linear way.
> >
> > - Dossy
> >
> > --
> > Dossy Shiobara                       mail: [EMAIL PROTECTED]
> > Panoptic Computer Network             web: http://www.panoptic.com/
>

Reply via email to