VServer 1.9.2 (patch-2.6.8.1-vs1.9.2.diff)
[linux-2.6.git] / fs / nfsd / auth.c
index 05822ee..8d35f45 100644 (file)
@@ -43,20 +43,20 @@ int nfsd_setuser(struct svc_rqst *rqstp, struct svc_export *exp)
        }
 
        if (cred->cr_uid != (uid_t) -1)
-               current->fsuid = INOXID_UID(cred->cr_uid, cred->cr_gid);
+               current->fsuid = INOXID_UID(1, cred->cr_uid, cred->cr_gid);
        else
                current->fsuid = exp->ex_anon_uid;
        if (cred->cr_gid != (gid_t) -1)
-               current->fsgid = INOXID_GID(cred->cr_uid, cred->cr_gid);
+               current->fsgid = INOXID_GID(1, cred->cr_uid, cred->cr_gid);
        else
                current->fsgid = exp->ex_anon_gid;
        
-       current->xid = INOXID_XID(cred->cr_uid, cred->cr_gid, 0);
+       current->xid = INOXID_XID(1, cred->cr_uid, cred->cr_gid, 0);
 
        if (!cred->cr_group_info)
                return -ENOMEM;
        ret = set_current_groups(cred->cr_group_info);
-       if ((cred->cr_uid)) {
+       if (INOXID_UID(1, cred->cr_uid, cred->cr_gid)) {
                cap_t(current->cap_effective) &= ~CAP_NFSD_MASK;
        } else {
                cap_t(current->cap_effective) |= (CAP_NFSD_MASK &