Whamcloud - gitweb
LU-11696 utils: "lfs getsom" returns "24" to userspace 14/33714/2
authorQian Yingjin <qian@ddn.com>
Mon, 26 Nov 2018 02:11:06 +0000 (10:11 +0800)
committerOleg Drokin <green@whamcloud.com>
Fri, 4 Jan 2019 04:48:07 +0000 (04:48 +0000)
The "lfs getsom" command always returns "24" to userspace because
"rc = 24" (sizeof(struct lustre_som_attrs)) after fetching the
xattr from the kernel.
In this patch, rc is set to 0 if the lfs_getsom()->lgetxattr()
call returns a positive value.

Signed-off-by: Qian Yingjin <qian@ddn.com>
Change-Id: Ie3151f67b5ce2b5b2bc35a4b6528ba9a20a5db9f
Reviewed-on: https://review.whamcloud.com/33714
Tested-by: Jenkins
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: James Nunez <jnunez@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>

No differences found