nfsd4: fix nfs4 stateid leak
authorJ. Bruce Fields <bfields@redhat.com>
Wed, 29 Aug 2012 22:21:58 +0000 (15:21 -0700)
committerJ. Bruce Fields <bfields@redhat.com>
Mon, 10 Sep 2012 14:55:14 +0000 (10:55 -0400)
commitcf9182e90b2af04245ac4fae497fe73fc71285b4
treea4659b22d9d2b35a168cbcf7f7c057412129d0c1
parent8a4c6e19cfed5e650045312affed7e6056383278
nfsd4: fix nfs4 stateid leak

Processes that open and close multiple files may end up setting this
oo_last_closed_stid without freeing what was previously pointed to.
This can result in a major leak, visible for example by watching the
nfsd4_stateids line of /proc/slabinfo.

Reported-by: Cyril B. <cbay@excellency.fr>
Tested-by: Cyril B. <cbay@excellency.fr>
Cc: stable@vger.kernel.org
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
fs/nfsd/nfs4state.c