Skip to content

Commit

Permalink
NFSv4: Fix an rpc_cred reference leakage in fs/nfs/delegation.c
Browse files Browse the repository at this point in the history
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
  • Loading branch information
Trond Myklebust authored and Trond Myklebust committed Oct 19, 2007
1 parent a49c3c7 commit 603c83d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion fs/nfs/delegation.c
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,8 @@ int nfs_inode_set_delegation(struct inode *inode, struct rpc_cred *cred, struct
spin_unlock(&inode->i_lock);

spin_unlock(&clp->cl_lock);
kfree(delegation);
if (delegation != NULL)
nfs_free_delegation(delegation);
return status;
}

Expand Down

0 comments on commit 603c83d

Please sign in to comment.