SCCS-vsn: sys/kern/vfs_syscalls.c 7.3
SCCS-vsn: sys/ufs/ffs/ffs_vnops.c 7.3
SCCS-vsn: sys/ufs/ffs/ufs_vnops.c 7.3
SCCS-vsn: sys/ufs/lfs/lfs_vnops.c 7.3
SCCS-vsn: sys/ufs/ufs/ufs_vnops.c 7.3
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*
- * @(#)vfs_syscalls.c 7.2 (Berkeley) %G%
+ * @(#)vfs_syscalls.c 7.3 (Berkeley) %G%
ip->i_nlink = 1;
ip->i_uid = u.u_uid;
ip->i_gid = pdir->i_gid;
ip->i_nlink = 1;
ip->i_uid = u.u_uid;
ip->i_gid = pdir->i_gid;
- if (ip->i_mode & ISGID && !groupmember(ip->i_gid))
+ if (ip->i_mode & ISGID && !groupmember(ip->i_gid) && !suser())
ip->i_mode &= ~ISGID;
#ifdef QUOTA
ip->i_dquot = inoquota(ip);
ip->i_mode &= ~ISGID;
#ifdef QUOTA
ip->i_dquot = inoquota(ip);
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*
- * @(#)ffs_vnops.c 7.2 (Berkeley) %G%
+ * @(#)ffs_vnops.c 7.3 (Berkeley) %G%
ip->i_nlink = 1;
ip->i_uid = u.u_uid;
ip->i_gid = pdir->i_gid;
ip->i_nlink = 1;
ip->i_uid = u.u_uid;
ip->i_gid = pdir->i_gid;
- if (ip->i_mode & ISGID && !groupmember(ip->i_gid))
+ if (ip->i_mode & ISGID && !groupmember(ip->i_gid) && !suser())
ip->i_mode &= ~ISGID;
#ifdef QUOTA
ip->i_dquot = inoquota(ip);
ip->i_mode &= ~ISGID;
#ifdef QUOTA
ip->i_dquot = inoquota(ip);
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*
- * @(#)ufs_vnops.c 7.2 (Berkeley) %G%
+ * @(#)ufs_vnops.c 7.3 (Berkeley) %G%
ip->i_nlink = 1;
ip->i_uid = u.u_uid;
ip->i_gid = pdir->i_gid;
ip->i_nlink = 1;
ip->i_uid = u.u_uid;
ip->i_gid = pdir->i_gid;
- if (ip->i_mode & ISGID && !groupmember(ip->i_gid))
+ if (ip->i_mode & ISGID && !groupmember(ip->i_gid) && !suser())
ip->i_mode &= ~ISGID;
#ifdef QUOTA
ip->i_dquot = inoquota(ip);
ip->i_mode &= ~ISGID;
#ifdef QUOTA
ip->i_dquot = inoquota(ip);
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*
- * @(#)lfs_vnops.c 7.2 (Berkeley) %G%
+ * @(#)lfs_vnops.c 7.3 (Berkeley) %G%
ip->i_nlink = 1;
ip->i_uid = u.u_uid;
ip->i_gid = pdir->i_gid;
ip->i_nlink = 1;
ip->i_uid = u.u_uid;
ip->i_gid = pdir->i_gid;
- if (ip->i_mode & ISGID && !groupmember(ip->i_gid))
+ if (ip->i_mode & ISGID && !groupmember(ip->i_gid) && !suser())
ip->i_mode &= ~ISGID;
#ifdef QUOTA
ip->i_dquot = inoquota(ip);
ip->i_mode &= ~ISGID;
#ifdef QUOTA
ip->i_dquot = inoquota(ip);
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*
- * @(#)ufs_vnops.c 7.2 (Berkeley) %G%
+ * @(#)ufs_vnops.c 7.3 (Berkeley) %G%
ip->i_nlink = 1;
ip->i_uid = u.u_uid;
ip->i_gid = pdir->i_gid;
ip->i_nlink = 1;
ip->i_uid = u.u_uid;
ip->i_gid = pdir->i_gid;
- if (ip->i_mode & ISGID && !groupmember(ip->i_gid))
+ if (ip->i_mode & ISGID && !groupmember(ip->i_gid) && !suser())
ip->i_mode &= ~ISGID;
#ifdef QUOTA
ip->i_dquot = inoquota(ip);
ip->i_mode &= ~ISGID;
#ifdef QUOTA
ip->i_dquot = inoquota(ip);