[CRIU] Re: [PATCH 0/8] Inotify support v7

Cyrill Gorcunov gorcunov at openvz.org
Tue Apr 17 12:24:34 EDT 2012


On Tue, Apr 17, 2012 at 08:20:12PM +0400, Pavel Emelyanov wrote:
> On 04/12/2012 07:53 PM, Cyrill Gorcunov wrote:
> > On Thu, Apr 12, 2012 at 7:50 PM, Cyrill Gorcunov <gorcunov at openvz.org> wrote:
> >> Hi, here is new versoin for inotify support.
> >> Please review.
> >>
> > Forgot to attach kernel patch. Here is it.
> 
> > @@ -660,6 +765,11 @@ static int inotify_new_watch(struct fsno
> >                 goto out_err;
> >         }
> > 
> > +#if defined(CONFIG_CHECKPOINT_RESTORE) && defined(CONFIG_EXPORTFS)
> > +       dget(dentry);
> > +       tmp_i_mark->fsn_mark.target = dentry;
> > +#endif
> > +
> >         /* increment the number of watches the user has */
> >         atomic_inc(&group->inotify_data.user->inotify_watches);
> > 
> 
> dentry refcnt leak

Where? We have

inotify_new_watch
  dget(dentry);
  tmp_i_mark->fsn_mark.target = dentry;

fsnotify_put_mark
  dput(mark->target);
  mark->free_mark(mark);

	Cyrill


More information about the CRIU mailing list