]> git.baikalelectronics.ru Git - kernel.git/commit
ocfs2: Check search result in ocfs2_xattr_block_get()
authorTiger Yang <tiger.yang@oracle.com>
Sun, 2 Nov 2008 11:04:21 +0000 (19:04 +0800)
committerMark Fasheh <mfasheh@suse.com>
Mon, 10 Nov 2008 17:51:47 +0000 (09:51 -0800)
commit1bb543307b1cf9b0517c60be2d7d43d81136b1da
treec57a634cae86c83db4e3067af8ccf83805d2bf90
parentd583d76c62dd401303a3f5c4ba56b65299c49f07
ocfs2: Check search result in ocfs2_xattr_block_get()

ocfs2_xattr_block_get() calls ocfs2_xattr_search() to find an external
xattr, but doesn't check the search result that is passed back via struct
ocfs2_xattr_search. Add a check for search result, and pass back -ENODATA if
the xattr search failed. This avoids a later NULL pointer error.

Signed-off-by: Tiger Yang <tiger.yang@oracle.com>
Signed-off-by: Mark Fasheh <mfasheh@suse.com>
fs/ocfs2/xattr.c