The following test script:
#!/bin/bash
f() { :; }
while :; do
coproc f par1
wait $COPROC_PID
done
floods the console with:
./debug.sh: line 7: warning: execute_coproc: coproc [8740:COPROC] still exists
./debug.sh: line 7: warning: execute_coproc: coproc [8741:COPROC] still exists
That is, wait
doesn't wait for the coprocess to terminate.
Bash version is 4.2.0(5)-release.
This does not happen with 4.1.5(1)-release.
Do you think it is a bug?