Skip to content
Commit 7175fe90 authored by Yanchuan Nian's avatar Yanchuan Nian Committed by Trond Myklebust
Browse files

nfs: Check whether a layout pointer is NULL before free it



The new layout pointer in pnfs_find_alloc_layout() may be NULL because of
out of memory. we must do some check work, otherwise pnfs_free_layout_hdr()
will go wrong because it can not deal with a NULL pointer.

Signed-off-by: default avatarYanchuan Nian <ycnian@gmail.com>
Signed-off-by: default avatarTrond Myklebust <Trond.Myklebust@netapp.com>
parent 8d96b106
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment