version 1.3, 2003/06/29 22:31:09 |
version 1.3.2.4, 2005/03/04 16:51:46 |
Line 137 msdosfs_lookup(v) |
|
Line 137 msdosfs_lookup(v) |
|
/* |
/* |
* Check accessiblity of directory. |
* Check accessiblity of directory. |
*/ |
*/ |
if ((error = VOP_ACCESS(vdp, VEXEC, cnp->cn_cred, cnp->cn_proc)) != 0) |
if ((error = VOP_ACCESS(vdp, VEXEC, cnp->cn_cred, cnp->cn_lwp)) != 0) |
return (error); |
return (error); |
|
|
if ((flags & ISLASTCN) && (vdp->v_mount->mnt_flag & MNT_RDONLY) && |
if ((flags & ISLASTCN) && (vdp->v_mount->mnt_flag & MNT_RDONLY) && |
|
|
* Access for write is interpreted as allowing |
* Access for write is interpreted as allowing |
* creation of files in the directory. |
* creation of files in the directory. |
*/ |
*/ |
error = VOP_ACCESS(vdp, VWRITE, cnp->cn_cred, cnp->cn_proc); |
error = VOP_ACCESS(vdp, VWRITE, cnp->cn_cred, cnp->cn_lwp); |
if (error) |
if (error) |
return (error); |
return (error); |
|
|
|
|
slotoffset += |
slotoffset += |
sizeof(struct direntry) * (wincnt - slotcount); |
sizeof(struct direntry) * (wincnt - slotcount); |
} |
} |
|
|
/* |
/* |
* Return an indication of where the new directory |
* Return an indication of where the new directory |
* entry should be put. |
* entry should be put. |
|
|
/* |
/* |
* Write access to directory required to delete files. |
* Write access to directory required to delete files. |
*/ |
*/ |
error = VOP_ACCESS(vdp, VWRITE, cnp->cn_cred, cnp->cn_proc); |
error = VOP_ACCESS(vdp, VWRITE, cnp->cn_cred, cnp->cn_lwp); |
if (error) |
if (error) |
return (error); |
return (error); |
|
|
|
|
if (blkoff == MSDOSFSROOT_OFS) |
if (blkoff == MSDOSFSROOT_OFS) |
return EROFS; /* really? XXX */ |
return EROFS; /* really? XXX */ |
|
|
error = VOP_ACCESS(vdp, VWRITE, cnp->cn_cred, cnp->cn_proc); |
error = VOP_ACCESS(vdp, VWRITE, cnp->cn_cred, cnp->cn_lwp); |
if (error) |
if (error) |
return (error); |
return (error); |
|
|