]> git.karo-electronics.de Git - mv-sheeva.git/blobdiff - fs/nfs/nfs3proc.c
NFS: Fix the ftruncate() credential problem
[mv-sheeva.git] / fs / nfs / nfs3proc.c
index cf7d4e5927d6be2d5e49f7995cd88cce8e0430b2..b9c2d995332b0fe577e6491829fbb54a7dd4fbb7 100644 (file)
@@ -129,6 +129,8 @@ nfs3_proc_setattr(struct dentry *dentry, struct nfs_fattr *fattr,
        int     status;
 
        dprintk("NFS call  setattr\n");
+       if (sattr->ia_valid & ATTR_FILE)
+               msg.rpc_cred = nfs_file_cred(sattr->ia_file);
        nfs_fattr_init(fattr);
        status = rpc_call_sync(NFS_CLIENT(inode), &msg, 0);
        if (status == 0)