aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/sysctl_binary.c
diff options
context:
space:
mode:
authorKeith Mannthey <keith.mannthey@intel.com>2013-07-23 00:07:02 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-07-23 13:45:08 -0700
commitcb6a2db640d94a9dc29dabb9bf58d4ff2531d42c (patch)
tree1775642bd439d82d86fda8bc5eab0d1b60662be8 /kernel/sysctl_binary.c
parentstaging/lustre/llite: return valid fsid for statfs (diff)
staging/lustre/llite: error of listxattr when buffer is small
According to the standard, listxattr(2) should return -1 and errno should be set to ERANGE if the size of the list buffer is too small to hold the result. However ll_listxattr() will return a value bigger than the size of buffer in some cases. Let's assume listxattr(2) returns SIZE when it is called with a large enough list buffer. If it's called again with a list buffer whose size is smaller than SIZE but bigger than (SIZE - 12), then listxattr(2) will return SIZE too. This patch fixes the problem. Original patch by Li Xi <pkuelelixi@gmail.com> Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3403 Lustre-change: http://review.whamcloud.com/6463 Signed-off-by: Keith Mannthey <keith.mannthey@intel.com> Reviewed-by: Li Xi <pkuelelixi@gmail.com> Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com> Reviewed-by: Oleg Drokin <oleg.drokin@intel.com> Signed-off-by: Peng Tao <tao.peng@emc.com> Signed-off-by: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'kernel/sysctl_binary.c')
0 files changed, 0 insertions, 0 deletions