Whamcloud - gitweb
LU-1746 osd-zfs: fix LU_BUF_NULL in osd_xattr_list()
authorMinh Diep <minh.diep@intel.com>
Fri, 31 Aug 2012 15:33:39 +0000 (08:33 -0700)
committerOleg Drokin <green@whamcloud.com>
Mon, 17 Sep 2012 22:12:45 +0000 (18:12 -0400)
commit47accf4c7875c8f0fa89cd3ed2f38d8f7ed0586e
tree6572af1f0c8241d9d1eeecbaeef51f5736edd447
parentee0a3e8ae08b7b72598cb797d023046b9f95ab81
LU-1746 osd-zfs: fix LU_BUF_NULL in osd_xattr_list()

== sanity test 17k: symlinks: rsync with xattrs enabled
=========================== 17:49:09 (1344332949)
sending incremental file list
rsync: get_xattr_names: llistxattr(".",0) failed: Numerical
result out of range (34)
[...]

It happened like this:

  osd_sa_xattr_list()
  osd_xattr_list()
  ...
  mdt_getxattr_pack_reply()
  mdt_getxattr()

mdt_getxattr_pack_reply() passed LU_BUF_NULL as lu_buf to
learn how big the buffer should be.  osd_xattr_list() does
not support such queries with NULL buffers.

Test-Parameters: envdefinition=USE_OFD=yes,LOAD_MODULES_REMOTE=true
Signed-off-by: Minh Diep <minh.diep@intel.com>
Change-Id: I1aa63d9774770c14db2b332e634734cda3a160b6
Reviewed-on: http://review.whamcloud.com/3863
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Li Wei <liwei@whamcloud.com>
lustre/osd-zfs/osd_xattr.c