I think for files, doing a modules for ns_sopen, ns_sread, ns_sgets, ns_sclose,
ns_sputs would be pretty simple, like a few lines per routine.  The C library
should coordinate thread access for you, so I don't think you would need
a bunch of mutex garbage, other than maybe to update a file handle table
(if you wanted one).  Could be done just with using FD's as the numbers
too - that's what TCL does.  Then no file handle table is necessary.

Jim

>
> Kevin Lawver wrote:
> >
> > Hi again,
> >        In the adp/tcl docs, there are mentions (ns_mutex for example) of a
> > command called "detach".  It doesn't exist, or if it does, it's not called
> > "detach".  Can someone shed some light on if a command that does what detach
> > looks like it's supposed to do exists and if so, what is it?
> >
> > Thanks,
> > Kevin Lawver
>
> detach was used to place tcl channels / file handles into and area that
> would not be
> cleaned up when the interpreter went away.
>
> detach does not exist in 3.x due to the fact that
> the way interpreters are handled changed quite a bit.
> re-implementing the command was not  particularly straightforward
> and it ended up not getting done..
>
> -mike
>

Reply via email to