Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys ISSYMLINK is now only referenced inside vfs_lookup.c, an...



details:   https://anonhg.NetBSD.org/src/rev/115907a216f2
branches:  trunk
changeset: 764365:115907a216f2
user:      dholland <dholland%NetBSD.org@localhost>
date:      Mon Apr 18 00:40:53 2011 +0000

description:
ISSYMLINK is now only referenced inside vfs_lookup.c, and not needed
there, so get rid of it.

diffstat:

 sys/kern/vfs_lookup.c |  13 ++++---------
 sys/sys/namei.src     |   5 ++---
 2 files changed, 6 insertions(+), 12 deletions(-)

diffs (94 lines):

diff -r 7e32e4ed67d7 -r 115907a216f2 sys/kern/vfs_lookup.c
--- a/sys/kern/vfs_lookup.c     Mon Apr 18 00:38:33 2011 +0000
+++ b/sys/kern/vfs_lookup.c     Mon Apr 18 00:40:53 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: vfs_lookup.c,v 1.175 2011/04/14 15:29:25 yamt Exp $    */
+/*     $NetBSD: vfs_lookup.c,v 1.176 2011/04/18 00:40:53 dholland Exp $        */
 
 /*
  * Copyright (c) 1982, 1986, 1989, 1993
@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vfs_lookup.c,v 1.175 2011/04/14 15:29:25 yamt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vfs_lookup.c,v 1.176 2011/04/18 00:40:53 dholland Exp $");
 
 #include "opt_magiclinks.h"
 
@@ -226,7 +226,7 @@
  *
  * System-call-layer level code that is going to call namei should
  * first create a pathbuf and adjust all the bells and whistles on it
- * as needed by context
+ * as needed by context.
  */
 
 struct pathbuf {
@@ -318,7 +318,7 @@
 
 /*
  * XXX should not exist:
- *   1. whether a pointer is kernel or user should be statically checkable
+ *   1. whether a pointer is kernel or user should be statically checkable.
  *   2. copyin should be handled by the upper part of the syscall layer,
  *      not in here.
  */
@@ -1118,8 +1118,6 @@
                 * (currently, this may consume more than one)
                 */
 
-               cnp->cn_flags &= ~ISSYMLINK;
-
     dirloop:
                /*
                 * If we have a leading string of slashes, remove
@@ -1203,7 +1201,6 @@
                if (namei_atsymlink(state, foundobj)) {
                        ndp->ni_pathlen += state->slashes;
                        ndp->ni_next -= state->slashes;
-                       cnp->cn_flags |= ISSYMLINK;
                        if (neverfollow) {
                                error = EINVAL;
                        } else {
@@ -1513,7 +1510,6 @@
        state->docache = 1;
        state->rdonly = cnp->cn_flags & RDONLY;
        ndp->ni_dvp = NULL;
-       cnp->cn_flags &= ~ISSYMLINK;
 
        cnp->cn_consume = 0;
        cp = NULL;
@@ -1617,7 +1613,6 @@
         * Setup: break out flag bits into variables.
         */
        rdonly = cnp->cn_flags & RDONLY;
-       cnp->cn_flags &= ~ISSYMLINK;
 
        /*
         * Search a new directory.
diff -r 7e32e4ed67d7 -r 115907a216f2 sys/sys/namei.src
--- a/sys/sys/namei.src Mon Apr 18 00:38:33 2011 +0000
+++ b/sys/sys/namei.src Mon Apr 18 00:40:53 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: namei.src,v 1.22 2011/01/07 11:25:10 pooka Exp $       */
+/*     $NetBSD: namei.src,v 1.23 2011/04/18 00:40:54 dholland Exp $    */
 
 /*
  * Copyright (c) 1985, 1989, 1991, 1993
@@ -154,14 +154,13 @@
 NAMEIFL        ISDOTDOT        0x0002000       /* current component name is .. */
 NAMEIFL        MAKEENTRY       0x0004000       /* entry is to be added to name cache */
 NAMEIFL        ISLASTCN        0x0008000       /* this is last component of pathname */
-NAMEIFL        ISSYMLINK       0x0010000       /* symlink needs interpretation */
 NAMEIFL        ISWHITEOUT      0x0020000       /* found whiteout */
 NAMEIFL        DOWHITEOUT      0x0040000       /* do whiteouts */
 NAMEIFL        REQUIREDIR      0x0080000       /* must be a directory */
 NAMEIFL        CREATEDIR       0x0200000       /* trailing slashes are ok */
 NAMEIFL        INRENAME        0x0400000       /* operation is a part of ``rename'' */
 NAMEIFL        INRELOOKUP      0x0800000       /* set while inside relookup() */
-NAMEIFL        PARAMASK        0x0efe300       /* mask of parameter descriptors */
+NAMEIFL        PARAMASK        0x0eee300       /* mask of parameter descriptors */
 
 /*
  * Initialization of an nameidata structure.



Home | Main Index | Thread Index | Old Index