summaryrefslogtreecommitdiffstats
path: root/fs/orangefs/file.c
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@oracle.com>2017-05-22 15:08:31 +0300
committerMike Marshall <hubcap@omnibond.com>2017-09-14 14:58:27 -0400
commit5f13e58767a53ebb54265e03c0c4a67650286263 (patch)
tree8e7a067fbf6b4d8b55d3ee1f336d731d172520fb /fs/orangefs/file.c
parentba5e79ea183a2b809a9bbd2f8d76dc69ca32a92b (diff)
downloadblackbird-obmc-linux-5f13e58767a53ebb54265e03c0c4a67650286263.tar.gz
blackbird-obmc-linux-5f13e58767a53ebb54265e03c0c4a67650286263.zip
orangefs: off by ones in xattr size checks
A previous patch which claimed to remove off by ones actually introduced them. strlen() returns the length of the string not including the NUL character. We are using strcpy() to copy "name" into a buffer which is ORANGEFS_MAX_XATTR_NAMELEN characters long. We should make sure to leave space for the NUL, otherwise we're writing one character beyond the end of the buffer. Fixes: e675c5ec51fe ("orangefs: clean up oversize xattr validation") Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Mike Marshall <hubcap@omnibond.com>
Diffstat (limited to 'fs/orangefs/file.c')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud