I was using a tree created by alloctree(), 9pfile(2) to write a
synthetic filesystem and got
into a problem I have seen before, but I can“t remember if I asked
about it here (google
doesn't find anything).

There is no way to register a close() function in Srv which can be
called when a clunk
is received for an open file.

The solution may, alternatively be to register a clunk()
function and each can do what they want with it though I
do not like it because I feel I should receive things related
with files and not with fids.

This is important to do garbage collection in some
cases (for example if you open something when you get an open and want to
close it). Is there a reason for this function not existing? am I
missing something?.

At some point in the past I had a modified version of the library (my
proposed solution)
and at another I played with the references (very ugly) if my memory
serves right.
--
- curiosity sKilled the cat

Reply via email to