lkml.org 
[lkml]   [2015]   [May]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 47/79] namei: move link/cookie pairs into nameidata
On Wed, May 06, 2015 at 12:42:54PM +1000, NeilBrown wrote:
> > static int link_path_walk(const char *name, struct nameidata *nd)
> > {
> > - struct saved {
> > - struct path link;
> > - void *cookie;
> > - const char *name;
> > - } stack[MAX_NESTED_LINKS], *last = stack + nd->depth - 1;
> > + struct saved *last = nd->stack;
>
> This looks wrong. 'last' used to be dependent on nd->depth, now it isn't.

On the entry to link_path_walk() we have nd->depth == 0.

And nd->depth and last are changed in sync.


\
 
 \ /
  Last update: 2015-05-06 10:01    [W:0.187 / U:0.604 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site