diff options
author | eivind <eivind@FreeBSD.org> | 1998-02-04 01:16:03 +0000 |
---|---|---|
committer | eivind <eivind@FreeBSD.org> | 1998-02-04 01:16:03 +0000 |
commit | 099975fa279c4c88e3111370e503c46e8c002061 (patch) | |
tree | b111c2a04253071e953ec2901e785a01c05d75ef /sys/gnu | |
parent | 939d87b65e1bfad79101648ca23635f80c0d8140 (diff) | |
download | FreeBSD-src-099975fa279c4c88e3111370e503c46e8c002061.zip FreeBSD-src-099975fa279c4c88e3111370e503c46e8c002061.tar.gz |
Make LINT at least compile. This faithfully duplicate the changes
done to ufs/ufs/ufs_vnops.c for the same problem, but I don't know if
that will actually make SUIDDIR work for ext2fs.
Diffstat (limited to 'sys/gnu')
-rw-r--r-- | sys/gnu/ext2fs/ext2_vnops.c | 16 | ||||
-rw-r--r-- | sys/gnu/fs/ext2fs/ext2_vnops.c | 16 |
2 files changed, 16 insertions, 16 deletions
diff --git a/sys/gnu/ext2fs/ext2_vnops.c b/sys/gnu/ext2fs/ext2_vnops.c index 38a8460..91a89c9 100644 --- a/sys/gnu/ext2fs/ext2_vnops.c +++ b/sys/gnu/ext2fs/ext2_vnops.c @@ -836,7 +836,7 @@ ext2_mkdir(ap) * and we are not giving it TOO root, (would subvert quotas) * then go ahead and give it to the other user. * The new directory also inherits the SUID bit. - * If user's UID an ddir UID are the same, + * If user's UID and dir UID are the same, * 'give it away' so that the SUID is still forced on. */ if ( (dvp->v_mount->mnt_flag & MNT_SUIDDIR) && @@ -844,7 +844,7 @@ ext2_mkdir(ap) dmode |= ISUID; ip->i_uid = dp->i_uid; #ifdef QUOTA - if (pdir->i_uid != cnp->cn_cred->cr_uid) { + if (dp->i_uid != cnp->cn_cred->cr_uid) { /* * make sure the correct user gets charged * for the space. @@ -856,7 +856,7 @@ ext2_mkdir(ap) ucred.cr_uid = ip->i_uid; ucred.cr_ngroups = 1; ucred.cr_groups[0] = dp->i_gid; - ucp = *ucred; + ucp = &ucred; } #endif I } else { @@ -865,8 +865,8 @@ ext2_mkdir(ap) #ifdef QUOTA if ((error = getinoquota(ip)) || (error = chkiq(ip, 1, ucp, 0))) { - free(cnp->cn_pnbuf, M_NAMEI); - VOP_VFREE(tvp, ip->i_number, dmode); + zfree(namei_zone, cnp->cn_pnbuf); + UFS_VFREE(tvp, ip->i_number, dmode); vput(tvp); vput(dvp); return (error); @@ -1129,7 +1129,7 @@ ext2_makeinode(mode, dvp, vpp, cnp) ucred.cr_uid = ip->i_uid; ucred.cr_ngroups = 1; ucred.cr_groups[0] = pdir->i_gid; - ucp = *ucred; + ucp = &ucred; #endif I } else { ip->i_uid = cnp->cn_cred->cr_uid; @@ -1138,8 +1138,8 @@ ext2_makeinode(mode, dvp, vpp, cnp) #ifdef QUOTA if ((error = getinoquota(ip)) || (error = chkiq(ip, 1, ucp, 0))) { - free(cnp->cn_pnbuf, M_NAMEI); - VOP_VFREE(tvp, ip->i_number, mode); + zfree(namei_zone, cnp->cn_pnbuf); + UFS_VFREE(tvp, ip->i_number, mode); vput(tvp); vput(dvp); return (error); diff --git a/sys/gnu/fs/ext2fs/ext2_vnops.c b/sys/gnu/fs/ext2fs/ext2_vnops.c index 38a8460..91a89c9 100644 --- a/sys/gnu/fs/ext2fs/ext2_vnops.c +++ b/sys/gnu/fs/ext2fs/ext2_vnops.c @@ -836,7 +836,7 @@ ext2_mkdir(ap) * and we are not giving it TOO root, (would subvert quotas) * then go ahead and give it to the other user. * The new directory also inherits the SUID bit. - * If user's UID an ddir UID are the same, + * If user's UID and dir UID are the same, * 'give it away' so that the SUID is still forced on. */ if ( (dvp->v_mount->mnt_flag & MNT_SUIDDIR) && @@ -844,7 +844,7 @@ ext2_mkdir(ap) dmode |= ISUID; ip->i_uid = dp->i_uid; #ifdef QUOTA - if (pdir->i_uid != cnp->cn_cred->cr_uid) { + if (dp->i_uid != cnp->cn_cred->cr_uid) { /* * make sure the correct user gets charged * for the space. @@ -856,7 +856,7 @@ ext2_mkdir(ap) ucred.cr_uid = ip->i_uid; ucred.cr_ngroups = 1; ucred.cr_groups[0] = dp->i_gid; - ucp = *ucred; + ucp = &ucred; } #endif I } else { @@ -865,8 +865,8 @@ ext2_mkdir(ap) #ifdef QUOTA if ((error = getinoquota(ip)) || (error = chkiq(ip, 1, ucp, 0))) { - free(cnp->cn_pnbuf, M_NAMEI); - VOP_VFREE(tvp, ip->i_number, dmode); + zfree(namei_zone, cnp->cn_pnbuf); + UFS_VFREE(tvp, ip->i_number, dmode); vput(tvp); vput(dvp); return (error); @@ -1129,7 +1129,7 @@ ext2_makeinode(mode, dvp, vpp, cnp) ucred.cr_uid = ip->i_uid; ucred.cr_ngroups = 1; ucred.cr_groups[0] = pdir->i_gid; - ucp = *ucred; + ucp = &ucred; #endif I } else { ip->i_uid = cnp->cn_cred->cr_uid; @@ -1138,8 +1138,8 @@ ext2_makeinode(mode, dvp, vpp, cnp) #ifdef QUOTA if ((error = getinoquota(ip)) || (error = chkiq(ip, 1, ucp, 0))) { - free(cnp->cn_pnbuf, M_NAMEI); - VOP_VFREE(tvp, ip->i_number, mode); + zfree(namei_zone, cnp->cn_pnbuf); + UFS_VFREE(tvp, ip->i_number, mode); vput(tvp); vput(dvp); return (error); |