Fix for knfsd mkdir in linux-2.2.1

Trond Myklebust (trond.myklebust@fys.uio.no)
Mon, 15 Feb 1999 10:59:57 +0100 (CET)


Hi,

The following patch fixes the problem with mkdir clearing the setgid
bit on newly created directories (see Olaf's comment in the code).

Cheers,
Trond

--- linux/fs/nfsd/vfs.c-ac5 Wed Jan 27 22:49:46 1999
+++ linux/fs/nfsd/vfs.c Sat Feb 13 19:59:02 1999
@@ -734,7 +734,7 @@
* directories via NFS.
*/
err = 0;
- if ((iap->ia_valid &= (ATTR_UID|ATTR_GID|ATTR_MODE)) != 0)
+ if ((iap->ia_valid &= ~(ATTR_UID|ATTR_GID|ATTR_MODE)) != 0)
err = nfsd_setattr(rqstp, resfhp, iap);
out:
return err;

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/