please apply bash 5.0 patch 17
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
bash (Ubuntu) |
Fix Released
|
Medium
|
Matthieu Clemenceau | ||
Focal |
Fix Released
|
Medium
|
Matthieu Clemenceau |
Bug Description
This section is for Focal SRU purpose
[Impact]
From https:/
There were cases where bash 5.0 patch 16 reaped process substitution file descriptors (or FIFOs) and processes to early. This is a better fix for the problem that bash50-016 attempted to solve.
[Test Case]
This simple bash script pass when bash with patch 017 is installed
Recommend to run it before and after installing the update to notice the difference
```
#!/usr/bin/bash
ouch() {
cat < <(echo bar)
cat "$1"
}
ouch2() {
{ cat; } < <(echo bar)
cat "$1"
}
ouch <(echo "foo")
ouch2 <(echo "foo")
```
Expected output with the patch installed:
foo
bar
foo
bar
[Regression Potential]
This is an upstream patch level update with no additional modification. The regression potential should be fairly low. Also the patch is intended to only fix this problem.
Possible regression would be unforeseen additional process substitutions that upstream bash would share.
End SRU
------
Original Bug Description:
I am using Ubuntu 20.04 for development and has hit a bug in bash 5.0 patch 16.
I can't reproduce it in pure bash, but with bats from https:/
```
# cat << EOF > ya.bats
check() {
echo "check $@"
ls -l /proc/self/fd
}
@test "here file" {
check -p <(echo "hey")
false
}
EOF
$ bats ya.bats
```
Normally the output should contain the line
lr-x------ 1 kir kir 64 May 14 02:01 63 -> pipe:[4616918]
which is a result of a "here file" created by bash via <(echo "hey").
In my testing, about 50% of runs don't have /dev/fd/63 listed.
I found out this is a manifest of a bug introduced in bash 5.0 patch 16 (see http://
The bug is fixed in 5.0 patch 17 (see http://
Please update bash to patchlevel 17.
tags: | added: rls-ff-incoming |
Changed in bash (Ubuntu): | |
status: | New → Triaged |
importance: | Undecided → Medium |
Changed in bash (Ubuntu Focal): | |
status: | New → Triaged |
importance: | Undecided → Medium |
tags: | removed: rls-ff-incoming |
tags: | added: id-5ec6a2b21639eb7938a123eb |
Changed in bash (Ubuntu Focal): | |
assignee: | nobody → Matthieu Clemenceau (mclemenceau) |
Changed in bash (Ubuntu): | |
assignee: | nobody → Matthieu Clemenceau (mclemenceau) |
Changed in bash (Ubuntu Focal): | |
status: | Triaged → Confirmed |
Changed in bash (Ubuntu Focal): | |
status: | Confirmed → In Progress |
Here is a repro that does not involve bats:
https:/ /lists. gnu.org/ archive/ html/bug- bash/2020- 03/msg00062. html