Details
-
Bug
-
Resolution: Fixed
-
Minor
-
Lustre 2.7.0
-
3
-
16868
Description
sanity-hsm (and probably all test scripts) contains several instances of the following
local fid=$(make_large_for_striping $f) [ $? != 0 ] && skip "not enough free space" && return
This is wrong since the exit status of make_large_for_striping gets discarded when used with the local built-in.
If this is rewritten as
local fid fid=$(make_large_for_striping $f) [ $? != 0 ] && skip "not enough free space" && return
then it will work as intended.
From the Google Bash Style Guide "Declaration and assignment must be separate statements when the assignment value is provided by a command substitution; as the 'local' builtin does not propagate the exit code from the command substitution."