Re: How to monitor a directory in FreeBSD?
- In reply to: Craig Leres : "Re: How to monitor a directory in FreeBSD?"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 13 Aug 2022 19:15:19 UTC
On 8/13/22 18:51, Craig Leres wrote: > > The way I've done it is is to use EVFILT_VNODE/NOTE_WRITE to tell me > when the directory has changed and then roll my own opendir()/readdir() > code to detect what (if anything) was added or deleted. This looks like the most natural solution, but I would have to keep and remember the state to be able to tell the difference between the current state and the state before. This would add complexity to the code, but it shouldn't be that hard to implement in my use case. Thanks!