-
Bug
-
Resolution: Cannot Reproduce
-
Undefined
-
None
-
rhel-9.0.0
-
None
-
None
-
rhel-sst-cs-plumbers
-
ssg_core_services
-
None
-
False
-
-
None
-
None
-
None
-
None
-
If docs needed, set a value
-
-
Unspecified
-
None
Description of problem:
While running reproducers for bug 2062291, I have found that exit codes differ between RHEL7 and RHEL9.
Version-Release number of selected component (if applicable):
bash-5.1.8-4.el9.x86_64
How reproducible:
always
Steps to Reproduce:
1. create test script (bz2062291-2.sh) containing
set – $'\t'; IFS=$1 A=$1
[[ $@ ]]
2. bash bz2062291-2.sh ; echo $?
Actual results:
0
Expected results:
1
Additional info:
No arguments are passed to the testscript, so $@ should be empty.
Reading the manpage, there are two possibilities how to test non-zero lenght of a string, either using '-n string' or omitting the -n, so the test parentheses [[ ]] containing empty string should result in false, thus I believe the RHEL7 version is correct and RHEL9 version is wrong.
- external trackers