Whamcloud - gitweb
LU-14385 utils: add range check to strtol() in lfs.c 56/41756/4
authorJian Yu <yujian@whamcloud.com>
Thu, 11 Mar 2021 23:10:29 +0000 (15:10 -0800)
committerOleg Drokin <green@whamcloud.com>
Mon, 22 Mar 2021 16:26:16 +0000 (16:26 +0000)
commitb217593a9e68d15e34c257b8d9485d34d3ccbbec
treea78e0cd36a1a88d5e7dcbfd22ca3c8c98c3c67f2
parent67af976c806994cec27414d24b43f6519d72c240
LU-14385 utils: add range check to strtol() in lfs.c

Most of the strtol() and strtoll() functions called
in lfs.c did not check the range of the return value.
This patch fixes those issues.

Change-Id: I9ff51662bf0d2320961a7838da08f09552e9ef1e
Signed-off-by: Jian Yu <yujian@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/41756
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: John L. Hammond <jhammond@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/utils/lfs.c