> The below patch lets user space have more control over the inodes that> inotify will watch. It introduces two new flags. > > IN_ONLYDIR -- only watch the inode if it is a directory> This is needed to avoid the race that can occur when we want to be sure> that we are watching a directory.> > IN_DONT_FOLLOW -- don't follow a symlink. In combination with> IN_ONLYDIR we can make sure that we don't watch the target of symlinks.> > The issues the flags fix came up when writing the gnome-vfs inotify> backend. Default behaviour is unchanged.

Looks good to me, and I confirm we hit these issues in real-life withgnome-vfs.