]> git.baikalelectronics.ru Git - kernel.git/commit
nfsd4: fix bare destroy_session null dereference
authorJ. Bruce Fields <bfields@citi.umich.edu>
Sat, 1 May 2010 16:56:06 +0000 (12:56 -0400)
committerJ. Bruce Fields <bfields@citi.umich.edu>
Fri, 7 May 2010 23:08:47 +0000 (19:08 -0400)
commitb5e71000252856968791805b10939eb8e215f315
treef5cb399d4fc29aec57e700d2b77731fe68e4a537
parent0bb275b175ddba2fe0ecb4d9ece4ad876f281991
nfsd4: fix bare destroy_session null dereference

It's legal to send a DESTROY_SESSION outside any session (as the only
operation in a compound), in which case cstate->session will be NULL;
check for that case.

While we're at it, move these checks into a separate helper function.

Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
fs/nfsd/nfs4state.c