Whamcloud - gitweb
LU-15360 tests: Use saved value on EXIT/Restore 21/45821/2
authorArshad Hussain <arshad.hussain@aeoncomputing.com>
Fri, 10 Dec 2021 09:46:54 +0000 (15:16 +0530)
committerOleg Drokin <green@whamcloud.com>
Thu, 23 Dec 2021 07:21:22 +0000 (07:21 +0000)
commit9348b9a1e061243ff95c3b8bde69425829405efd
tree65378224916480a17c8af8638eec2e42ba3e1cec
parent9b0b7264a8d7a6a2abe681d15fefc88c27d20c1e
LU-15360 tests: Use saved value on EXIT/Restore

This was originally reported by shellcheck as
unused variable. However, on closer inspection
it appears that the restore on "EXIT" was
hard-coded to 0 (mostly this should be correct)
instead of using the original value of $old

This patch resets 'enable_chprojid_gid' value
to original value captured in $old instead of
hard-coded value of 0

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In ./lustre/tests/sanity-quota.sh line 4150:
local old=$(do_facet mds1 $LCTL get_param -n \
      ^-- SC2034: old appears unused. Verify it or export it.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Test-Parameters: trivial testlist=sanity-quota
Signed-off-by: Arshad Hussain <arshad.hussain@aeoncomputing.com>
Change-Id: I31e7a8a931d53a1fcb9d77ecf1759fce572bd52c
Reviewed-on: https://review.whamcloud.com/45821
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: James Nunez <jnunez@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/tests/sanity-quota.sh