lkml.org 
[lkml]   [2012]   [May]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH 00/16] vfs: atomic open v4 (part 1)
Date
Miklos Szeredi <miklos@szeredi.hu> wrote:

> > Also, does it make sense to combine:
> >
> > if (!S_ISREG(nd->inode->i_mode))
> > will_truncate = 0;
> >
> > with:
> >
> > int will_truncate = open_flag & O_TRUNC;
> >
> > up at the top of the function.
>
> We need to check nd->inode->i_mode *after* the lookup. So top of the
> function is not a good place.

Good point.

David


\
 
 \ /
  Last update: 2012-05-25 17:41    [W:0.127 / U:0.132 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site