bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: bash-4-2 issue


From: Chet Ramey
Subject: Re: bash-4-2 issue
Date: Thu, 11 Jan 2024 10:45:35 -0500
User-agent: Mozilla Thunderbird

On 1/10/24 5:33 PM, Grisha Levit wrote:
On Mon, Jan 8, 2024 at 7:04 AM Sam Kappen via Bug reports for the GNU
Bourne Again SHell <bug-bash@gnu.org> wrote:
We see that bash throws the "Operation not permitted" error when doing
chained pipe operation
along with a debug trap.

We set a debug trap here "my_debug" to save the terminal commands entered.
The GNU bash, version used is  4.2.

root@freescale-p2020ds:~/dir#  ls -l | grep a | grep b | grep c
-sh: child setpgid (4238 to 4232): Operation not permitted


root@freescale-p2020ds:~/dir# trap
trap -- '' TSTP
trap -- '' TTIN
trap -- '' TTOU
trap -- 'my_debug' DEBUG
root@freescale-p2020ds:~/dir#

Platform: Linux 3.10 kernel on PPC target.

It seems setpgid is failing because the process group of the pipeline does
not exist at that time.

This issue is not seen on bash version 4.4.

I'm not sure this is fixed. In all versions, including 4.2, 4.4, 5.2, and the
current devel version, I see what seems to be the same error, triggered by a
pipeline when job control is enabled and the DEBUG trap executes an external
command.

I can't reproduce this on RHEL 9, which is running Linux kernel version 5.
PGRP_PIPE is defined because the BASH_SYS_PGRP_SYNC test enables it.

--
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://tiswww.cwru.edu/~chet/

Attachment: OpenPGP_signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]