public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Olaf Dietsche <olaf.dietsche#list.linux-kernel@t-online.de>
To: Matthew Wilcox <willy@debian.org>
Cc: linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH] 2.5.50: unused code in link_path_walk()
Date: Fri, 06 Dec 2002 17:52:13 +0100	[thread overview]
Message-ID: <87of7zqede.fsf@goat.bogus.local> (raw)
In-Reply-To: 20021206161519.A16341@parcelfarce.linux.theplanet.co.uk

Matthew Wilcox <willy@debian.org> writes:

> @@ -700,7 +700,6 @@
>                                  if (this.name[1] != '.')
>                                          break;
>                                  follow_dotdot(&nd->mnt, &nd->dentry);
> -				inode = nd->dentry->d_inode;
>                                  /* fallthrough */
>                          case 1:
>                                  goto return_base;
>
> seems broken to me.  if follow_dotdot() changes nd->dentry (can happen!),
> inode needs to be changed.  look:
>
>         inode = nd->dentry->d_inode;
>         for(;;) {
>                 err = exec_permission_lite(inode);
>                 if (this.name[0] == '.') switch (this.len) {
>                         case 2: 
>                                 if (this.name[1] != '.')
>                                         break;
>                                 follow_dotdot(&nd->mnt, &nd->dentry);
>                                 inode = nd->dentry->d_inode;
>                                 /* fallthrough */
>                         case 1:
>                                 continue;
>                 }
>         }

You looked at the _first_ switch statement. You must go further down
to the _second_ switch. *There*, you don't need this assignment, AFAICS.

> btw, you should cc linux-fsdevel for patches to the VFS.

Thanks for this pointer, I'll spam linux-fsdevel in the future ;-).

Regards, Olaf.

  reply	other threads:[~2002-12-06 16:46 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-12-06 16:15 [PATCH] 2.5.50: unused code in link_path_walk() Matthew Wilcox
2002-12-06 16:52 ` Olaf Dietsche [this message]
  -- strict thread matches above, loose matches on Subject: below --
2002-12-04 23:09 Olaf Dietsche

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87of7zqede.fsf@goat.bogus.local \
    --to=olaf.dietsche#list.linux-kernel@t-online.de \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=willy@debian.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox