lkml.org 
[lkml]   [2014]   [Sep]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] fs: don't remove inotify watchers from alive inode-s
On Mon, Sep 08, 2014 at 04:01:56PM +0400, Andrey Vagin wrote:
> Currently watchers are removed in dentry_iput(), if n_link is zero.
> But other detries can be linked with this inode. For example if we
> create two hard links, open the first one and set a watcher on the
> second one. Then if we remove both links, the watcher will be removed.
> But we will have the alive file descriptor, which allows us to generate
> more events.
>
> With this patch, watchers will be removed, only if nlink is zero and
> i_dentry list is empty.

This changes the sequence of notifies userspace will see but I think there
were a bug before this patch, so

Reviewed-by: Cyrill Gorcunov <gorcunov@openvz.org>


\
 
 \ /
  Last update: 2014-09-08 15:01    [W:0.113 / U:0.564 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site